[vorbis-dev] Bride of vorbisfile questions

Joshua Haberman joshua at haberman.com
Wed Dec 17 14:54:52 PST 2003



On Tue, 2003-12-16 at 00:20, John Morton wrote:
> On Tuesday 16 December 2003 06:02, Joshua Haberman wrote:
> >  This would break a lot of the work I'm doing with lossless editing in
> >  Audacity.  A feature I am relying on is that two vorbis files can be
> >  concatenated into a single file and the resulting file is treated as a
> >  single bitstream.
> 
> I think there are only a few differences between phyisical streams and logical 
> streams, so the extra work to make them right may be fairly minimal. You'd 
> need to make sure that the final stream used the same serial numbers 
> throughout, and maybe do some work on the headers of the second one, which 
> may just mean deleteing them (or are their codebooks that you need to keep?).

There are two main reasons why I can't collapse all the data into a
single logical bitstream:

1. the physical bitstream may consist of data that came from several
different bitstreams, all with different codebooks.

2. the feature of the Ogg/Vorbis format that allows for sample accurate
slicing of already-compressed data using granulepos can only be used at
the beginning and end of a a logical bitstream.

(2) is really unfortunate.  I really wish something resembling this had
been included as part of the format:

http://www.xiph.org/archives/vorbis-dev/199911/0008.html

Even using the sub-optimal algorithm I am using (that creates multiple
logical bitstreams cut sample-accurately using granulepos) can't handle
one case that the scheme proposed in that message could have: the case
where you want a set of samples from an existing frame that is neither
at the beginning nor the end of the frame.  granulepos can't handle
this.

> I don't think relying on a physical bitstream being considered a single entity 
> by player software is a good plan in the long run.

The spec doesn't really speak to the semantics of what it means to have
chained bitstreams within a physical bitstream.  It's not clear to me
that either interpretation has more validity based on the spec.

For what it's worth, Monty's reply to the message referenced above cited
the "chaining" ability as a solution to the lossless editing problem,
which would appear to support my interpretation. 

Josh
--- >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