[vorbis-dev] streaming ogg questions

Firelight Multimedia support at fmod.org
Wed Oct 18 16:13:26 PDT 2000



Hi,
im trying to get my streamer working properly using the ogg layer, working
off the decoder_example.c
Im trying to reset the state of the stream, because the 8k the example reads
for the header gets played when i seek my file to 0 again to play the
stream, so the effect(bug) is the first part of the stream (1 or 2 seconds)
gets played twice.
I ripped this from vorbisfile
  ogg_stream_clear(&vf->os);
  vorbis_dsp_clear(&vf->vd);
  vorbis_block_clear(&vf->vb);
But all it does upon doing this is request data ('need more data') until it
runs out and doesnt decode anything :).. what am i doing wrong?

This will relate to seeking to an arbitrary point in the file as well  . .
i assume ill have to reset the ogg buffers etc so i can start decoding the
new data without having whats in the buffer play out first.  Can i seek to
any byte offset in the file and ogg handles it? or (from my preliminary look
through of vorbisfile), do i have to find a page boundary myself?

thanks
Brett.

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