[vorbis-dev] Ogg MIDI proposal

Lourens Veen
Sun, 26 Aug 2001 01:03:05 -0000

Jack Moffitt wrote:
>
> File Format
> ----------
> A file with Vorbis and Midi will look like:
>
> <Vorbis header pages><MIDI header page><Vorbis data
page><MIDI data page>...
>
> MIDI pages will be placed in sync with vorbis pages (immediately following
> their corresponding Vorbis page).  Since MIDIs are tiny, it is likely
> there will be very few pages of MIDI data.
>
> Each MIDI Ogg packet will contain rougly 512 bytes aligned to MIDI event
> boundaries.  This means approximately 8 MIDI packets will normally be place
> in an Ogg page.

I'm a bit concerned here about packet ordering in non-degenerate Ogg
streams. We could specify that a MIDI packet comes before the Vorbis
packet that should be played at the same time, but what if we have more
streams? Let's say we want to multiplex a Vorbis audio stream, Tarkin
video, XML subtitles, and DMX (?) data to control lights in the cinema.
How would we do that?

Why not just specify that a packet which should start being played at
time x is not allowed to come before any packets that end before or on
time x, and that packets should be ordered within that constraint in
order of size (ie smallest packet first) to make buffering most
efficient.

Did I miss anything?

Lourens