[vorbis-dev] timestamping / latency

John Ripley
Tue, 13 Jan 2004 05:55:34 -0000

> From: Segher Boessenkool [mailto:segher@kernel.crashing.org]
> Sent: 12 January 2004 23:39
> To: vorbis-dev@xiph.org
> Subject: Re: [vorbis-dev] timestamping / latency
>
> On 12-jan-04, at 2:51, Michael Smith wrote:
> > Note that for low-latency, the ogg layer is going to be causing you
> > lots of
> > problems - vorbis itself doesn't have particularly high
> latency, but
> > because
> > of the multiple vorbis packets per ogg page, the latency
> gets pretty
> > high.
>
> Vorbis itself has a latency of just one window size (which is
> max. 2048
> with current libvorbis encoders, i.e. about 50ms with normal sample
> rates),
> although the libvorbis implementation of the decoder (and
> especially the
> encoder) make for larger latencies.
>
> This still isn't worse than any of the other natural audio, good
> compression, codecs.
>
> But yeah, Ogg framing amplifies the latency a lot.  If that's
> a problem for
> your specialized application, nothing forces you to use Ogg
> -- just send the Vorbis packets with some other framing method.
>
> Segher

You could still use Ogg if you force a page out for each encoded packet.
That means you only have one packet per page, so the framing overhead will
be a lot higher (about 5-10%), but it will work without modifying the
decoder.

- John Ripley.