[theora-dev] Re: Final Ogg 1.0 submission to IETF

Jack Moffitt jack at xiph.org
Tue Mar 4 08:45:11 PST 2003



> The order-by-granulepos idea came out of 
> Jack's work on midi-over-ogg, I remember understanding that, but can't 
> recall the details. Maybe Jack can fill us in. I also remember talking 
> about order-by-granulpos-of-previous-page too, but that's not what 
> oggmerge does.

There's two philosophies:

1) Sort by the start granule pos on each page.  This means means that if
you have a page, you're likely to have all data you need to play that
page already.

2) Sort by end granulepos on each page.  This means that pages end
together.  You'll have to buffer quite a bit more I think, because the
midi page (for exmaple) would come at the end of the stream of vorbis
pages, none of which can be played without the midi.

Monty had assumed we'd use #2, but we ended up deciding on #1.  

The basic advantage was that I could send each page off to decode/play
without figuring out where it was supposed to go and not keeping a huge
buffer.  I just read off the ogg stream, tossing pages into 'decode
bins'.  In omplay, the midi clock timer is synced to the audio card
exactly (via ALSA).  So I didn't have to do any special work to keep
midi synced, just had to make sure the midi data was there to play.

jack.
--- >8 ----
List archives:  http://www.xiph.org/archives/
Ogg project homepage: http://www.xiph.org/ogg/
To unsubscribe from this list, send a message to 'theora-dev-request at xiph.org'
containing only the word 'unsubscribe' in the body.  No subject is needed.
Unsubscribe messages sent to the list will be ignored/filtered.



More information about the Theora-dev mailing list