[vorbis-dev] chaining_example.c: getting bitstream info

Monty xiphmont at xiph.org
Tue Nov 2 04:39:55 PST 1999



I've committed the first cut of lib/chaining_example.c to CVS.  It illustrates
how to open an OggVorbis bitstream and gather global information about the
bitstream like total playing time, chaining structure, etc.  This piece of code
knows all the tricks and should deal gracefully even with seriously botched
streams.

The code is tested with a few cases (including corrupt bitstreams), but is
still generally unproven.  It does not have random-access/seeking examples.
That's next.

To run the example, do something like encoder_example < test.ogg.  The redirect
(as opposed to a pipe) makes sure that stdin is an fd representing an actual
seekable file.

Monty

--- >8 ----
List archives:  http://www.xiph.org/archives/
Ogg project homepage: http://www.xiph.org/ogg/



More information about the Vorbis-dev mailing list