[vorbis-dev] streaming considerations
Michael Smith
msmith at labyrinth.net.au
Sat Sep 2 00:17:07 PDT 2000
At 04:53 PM 9/1/00 -0700, you wrote:
>After looking at streaming stuff, I figure there's a small change that
>we need to make to the way headers are done.
>
>Headers should be page aligned. Ie, when the header ends, the current
>page in the ogg stream should end, so that vorbis packets start in a
>fresh page.
>
>This is necessary because i don't want to have to repaginate the entire
>stream because I have to cache a header to be replayed to clients.
This sounds like a good idea to me anyway, but...
You don't (except in pathological cases which probably won't ever occur in
reality - and won't ever be produced by libvorbis as things stand) have to
repaginate the entire file.
You can get away with simply taking the left over audio from one page, and
tacking it onto the the start of the next page - so you only have to
rebuild the header pages, plus the one page immediately following the header.
Unfortunately, libvorbis doesn't give you a way to do this (unless it was
added recently and I didn't see it), at the moment, so changes are needed -
but the ability to force page ends (or prevent them, which is what we want
here) would be useful in other things too, I suspect.
Despite this, I agree that it would be good for libvorbis to (by default,
at least) end the current page after the headers end. This wouldn't be a
requirement of the format though, so I suppose you'd have to have code
(even if it wasn't usually used) to deal with the nastier cases.
Michael
--- >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 'vorbis-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 Vorbis-dev
mailing list