[Vorbis-dev] Splitting Ogg Vorbis file
Conrad Parker
conrad at metadecks.org
Sun Jun 28 03:06:12 PDT 2009
2009/6/28 ogg.k.ogg.k at googlemail.com <ogg.k.ogg.k at googlemail.com>:
>> So my questions are: what does "overlap-add nature of vorbis" means?
>
> Decoding a Vorbis packet makes use of the two previous packets
> (that's also known as 'preroll'). Thus, if you're missing those packets,
> you'll get different data out (though I don't know *how* different
> that output would be).
My understanding is that for Vorbis, no data will be produced until
the third packet is received, so if you're missing the 2 previous
preroll packets then the output PCM stream will simply be shorter, ie.
missing the first 2 packets worth of audio (a few hundredths of a
second).
For speex, I understand that data will be produced from the first
packets, but if the decoder is first fed a few earlier packets then
the PCM data output after the desired split point will be closer to
the original data. Jean-Marc once recommended 3 packets of preroll for
Speex.
> You'd need this even if you want to cut at a packet granularity.
Right, ie. the preroll packets should appear in both files.
Conrad.
More information about the Vorbis-dev
mailing list