MLQ (Media Library Query) file format and mime type proposal

Milosz Derezynski internalerror at gmail.com
Thu Jun 22 12:25:55 EEST 2006


Hi,

I'm one of the main authors of BMP 2 (still being worked on), and along the
way of reworking our library, i came across the idea of encoding library
queries as URIs, which may look like this:

"query:///?artist=Air&album=Moon%20Safari"

BMP 2 has a plugin archicture which is a small VFS on it's own, and we treat
certain things as "containers" (i.e. they "contain" URIs, like PLS
playlists, XSPF, M3U, etc).
Now i thought it might be not a bad idea to create a playlist format with
these query URLs, and i've called it "MLQ" for media library query. In
theory, it's not even
application specific. The keys (identifiers), like artist, album, etc, are
all based on GStreamer tag identifiers. (They could be maybe adapted to
http://www.freedesktop.org/wiki/Standards_2faudio_2dmetadata_2dspec , but it
seems insufficient and doesn't specify certain items, like musicbrainz
metadata, which GST does).

So i've called this file format "MLQ", with the extension .mlq, created a
mime package file for it:

<?xml version="1.0" encoding="UTF-8"?>
<mime-info xmlns="http://www.freedesktop.org/standards/shared-mime-info">
  <mime-type type="application/x-media-library-query">
         <comment xml:lang="en">Media Library Query List</comment>
         <magic priority="50">
            <match value="query:///" type="string" offset="0"/>
         </magic>
         <glob pattern="*.mlq"/>
  </mime-type>
</mime-info>

Adding a file of this type to BMPx, or just a plain query:/// URI itself
causes a library query and appending of the relevant items to the tracklist
(BMP is currently mostly based on the concept of a mutable playlist to which
items can be added from various sources, unlike e.g. RB which has mostly
immutable "Playlists", but allows for custom queues).

Another example is:

query:///?artist=Air&album=Moon%20Safari&title=La%20Femme%20d'Argent
query:///?artist=Air&album=Moon%20Safari&title=Sexy%20Boy
query:///?artist=Air&album=Moon%20Safari&title=All%20I%20Need
query:///?artist=Air&album=Moon%20Safari&title=Kelly,%20Watch%20The%20Stars!
query:///?artist=Air&album=Moon%20Safari&title=Talisman
query:///?artist=Air&album=Moon%20Safari&title=Remember
query:///?artist=Air&album=Moon%20Safari&title=You%20Make%20It%20Easy
query:///?artist=Air&album=Moon%20Safari&title=Ce%20Matin%20La
query:///?artist=Air&album=Moon%20Safari&title=New%20Star%20In%20The%20Sky
query:///?artist=Air&album=Moon%20Safari&title=Le%20Voyage%20De%20Penelope

Or it might just be:

query:///?genre=Jazz

Since this is very common, and having the discussions about a common music
database in mind, this seems like a useful proposal, since it is not player
specific.
This ships currently with BMP 2/BMPx SVN, and while i will ship this with
the 0.20 release (end-July) anyway, what does everyone think of this in a
broader context (common music database, etc)?

-- Milosz
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.freedesktop.org/archives/xdg/attachments/20060622/d123dbdb/attachment.htm 


More information about the xdg mailing list