[vorbis-dev] Couple more problems (ov_open_callbacks)
Brian Hook
bhook at pyrogon.com
Tue Sep 25 18:50:45 PDT 2001
I'm in the final throes of debugging (hopefully) and the last thing I'm
trying to do is figure out why I'm getting static instead of usable
data. I have a verified Ogg file (it plays fine in WMA); I've visibly
inspected the info struct and it matches my output format; I've verified
my audio playback code by using a generated sine wave (sounds correct).
So that leads to a problem with how I'm using ov_read(). I've modeled
my code around the sample code, and I check my error returns fairly
religiously. The only weird thing I'm doing is using
ov_open_callbacks(). My callback routines simply read data out of an
in-memory bit bucket, so there's not much code there, e.g. my read
function is basically:
memcpy(pDst, myStreamPtr, bytes );
myStreamPtr += bytes;
..etc. etc. I didn't bother implementing a close function (I just
stubbed it out).
Looking at my read callback, I always seem to get requests for one
object of varying size. I've modeled my callbacks on the stream IO CRTL
stuff (fseek/fread/ftell/fclose), including parameters and return
values. I assume this is correct?
Any other obvious problems I should look for? Barring any epiphanies, I
may end up having to implement a test version using ov_open to see if
it's my callbacks (which I suspect).
Thanks,
Brian
--- >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