W3C home > Mailing lists > Public > whatwg@whatwg.org > September 2012

Re: [whatwg] metadata attribute for media

From: Ralph Giles <giles@mozilla.com>
Date: Thu, 20 Sep 2012 16:32:19 -0700
Message-ID: <505BA783.2030202@mozilla.com>
To: whatwg@whatwg.org
Back in June, I proposed[1] a new attribute to get metadata "tag" data
out of media resources.

I've done an experimental implementation of this which is now in the
Firefox Aurora (alpha) channel[2] and Nightly development builds.

The method is media.mozGetMetadata() and it returns a new object each
time, whose properties are key:value pairs representing the metadata
tags from the file. Aurora supports this for Ogg Vorbis (.ogg) streams.
Nightly supports Opus (.opus) files as well.

Right now the method returns whatever set of tags happen to be in the
media stream, at least if they can be interpreted as unicode text. There
are several things I'd like to fix about this. Media formats generally
have rules about how to map various tags to a standard vocabulary. Right
now, web content has to implement those rules, but the user-agent is in
a better position to do so.

Also, a number of Mozilla (C++) developers I've talked to prefer a fixed
schema for metadata, rather than the more dynamic approach.

So, I'd like to do a new method which returns an object with a fixed
schema we can describe in idl, representing standard fields derived from
the dublic core tag set. The raw metadata would be available under the
old method for advanced applications.

Some metadata is also per-track, rather than per-stream, so it makes
sense to have these calls available on track objects as well as media
objects.

The most essential tags are dc:creator and dc:title. That covers almost
all player use cases. For per-track metadata, the language is perhaps
also useful for selection purposes. Are there any other tags folks would
like to see in the initial proposal?

 -r

[1]
http://lists.whatwg.org/pipermail/whatwg-whatwg.org/2012-June/036352.html
[2] available from aurora.mozilla.org
Received on Thursday, 20 September 2012 23:32:51 UTC

This archive was generated by hypermail 2.4.0 : Wednesday, 22 January 2020 16:59:45 UTC