[vlc-devel] [PATCH] Adding metadata support to web-plugin

Besnard Jean-Baptiste jbbesnard at actech-innovation.com
Tue Sep 8 12:26:36 CEST 2009


Hi,

Here I propose a patch which adds metadata support to the plugin. It
allows the retrieval of an arbitrary element described in libvlc_meta_t
enum.

The following command is added to the javascript API :

         string items.metadata(string meta_type, int item_id);

string meta_type can be one of the following (it is not case
sensitive) :

"Artist",
"Title",
"ArtworkURL",
"TrackNumber",
"Genre",
"Copyright",
"Description",
"Rating",
"Date",
"Setting",
"URL",
"Language",
"NowPlaying",
"Publisher",
"EncodedBy",
"TrackID".

int item_id can be either -1 in order to refer to the currently playing
item or the index of an item. 

If the call happens to fail, the function returns an empty string.

The "test.html" page has been modified to show the metadatas and
the artwork of the currently played file.


In order to prevent code repetition a new function is added to the
media_list API it allows the retrieval of metadata at a given index in
the media list.



Best regards,

Jean-Baptiste BESNARD.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-Adding-a-metadata-getter-to-libvlc-media-list.patch
Type: text/x-patch
Size: 5949 bytes
Desc: not available
URL: <http://mailman.videolan.org/pipermail/vlc-devel/attachments/20090908/114b4a99/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0002-Mozilla-Plugin-Adding-metadata-support-to-the-plug.patch
Type: text/x-patch
Size: 6000 bytes
Desc: not available
URL: <http://mailman.videolan.org/pipermail/vlc-devel/attachments/20090908/114b4a99/attachment-0001.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0003-Active-X-IDL-auto-generated-Files.patch
Type: text/x-patch
Size: 5727 bytes
Desc: not available
URL: <http://mailman.videolan.org/pipermail/vlc-devel/attachments/20090908/114b4a99/attachment-0002.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0004-ActiveX-Adding-Metadata-Support-to-the-plugin.patch
Type: text/x-patch
Size: 5554 bytes
Desc: not available
URL: <http://mailman.videolan.org/pipermail/vlc-devel/attachments/20090908/114b4a99/attachment-0003.bin>


More information about the vlc-devel mailing list