[theora-dev] Extension to Skeleton for multi-track media

Silvia Pfeiffer silviapfeiffer1 at gmail.com
Tue Mar 23 22:44:05 PDT 2010

On Wed, Mar 24, 2010 at 3:30 PM, Benjamin M. Schwartz
<bmschwar at fas.harvard.edu> wrote:
> Silvia Pfeiffer wrote:
>>> Why do you have to create an order? I cannot think of any programming task
>>> that requires such an ordering.
>> An index is the easiest way to address a track lacking any other
>> information. The serial number cannot be used for addressing, since it
>> should not be exposed, will not work across chained streams, and
>> nobody wants to deal with such long, meaningless numbers anyway.
> I don't see any need for a defined ordering on the tracks.  A correctly
> written script should not depend on the ordering at all, so there's no
> need to specify it.

We are using the order for addressing. In MPEG, you will address a
track with track[1], track[2] etc. Do you really want people to have
to use track[0435863137], track[1155223152] to address the different
tracks? I've indeed suggested that in HTML5 and been told off that
this is not usable or acceptable. Further, numbering elements through
in the JavaScript is a typical wain which DOM elements are addressed,
so it makes total sense to have that. And ... how are you going to use
serial numbers to discover the tracks, e.g. how many tracks are
present? Also, if you use the order given by serial numbers, then you
have to manually set the serial number, which is not how any tools
work right now - right now the serial numbers are transparent from
use. But, I can use oggz-merge to set the order of BOS pages by simply
providing the tracks in the right order. Dealing with serial numbers
really is an internal mechanism that should not be overloaded.

Can you show me concretely how you want the JavaScript to look for
determining the number of tracks of an Ogg file, for looping through
all the tracks of an Ogg file, for extracting the features of a
certain track (e.g. the role), and for turning off a certain track
using the proposed HTML5 JS API

> Also, BOS ordering won't work across chained streams, as the number of
> tracks and their order may be different in different streams.

If we count BOS pages, then the new chain simply provides the next
number in the order of tracks. So, if the first chain had 2 tracks
(no1 and 2), then the next chain might have 3 tracks (no3, 4 and 5).
For chained files, the browser has to do some special processing
anyway, so it would need to go through all the chains and determine
the number of tracks from that. But I would like to hear from Chris
Pearce if that would fit with the way in which he is implementing
chaining support into Firefox.

>  Heck, the
> whole nature of the content can be completely different in different
> streams.  Conversely, opaque identifiers like serial numbers _will_ work,
> because each serial number clearly refers to a single track from a single
> stream.

So does the index.

> As for identifying objects by long, meaningless numbers ... that's what a
> pointer is.  All objects in C and C++ are identified by these long,
> meaningless numbers.  You can just treat them as opaque tokens, and
> everything works fine.

Except that the serial numbers are not pointers, but identifiers and
requiring their use in JavaScript will make Ogg look ridiculous.


More information about the theora-dev mailing list