[vorbis] Using vorbisfile with an in-memory file instead of FILE*

Olaf van der Spek Olaf at XCC.TMFWeb.NL
Wed Dec 27 09:04:52 PST 2000



----- Original Message -----
From: "Michael Smith" <msmith at labyrinth.net.au>
To: <vorbis at xiph.org>
Sent: Monday, December 25, 2000 2:05 PM
Subject: Re: [vorbis] Using vorbisfile with an in-memory file instead of
FILE*

>
> >> Use ov_open_callbacks() and write callbacks which fake reading from a
file
> >> (while actually reading from memory buffers). vorbisfile is designed
for
> >> reading from a file, so the interface is a bit messy when you try to do
> >> this, but it is possible.
> >
> >I thought maybe it was possible with the two parameters that specify
you've
> >already read a bit (in this case the whole file), but that didn't work.
> >Is there some documentation of those callbacks?
> >I didn't find very much docs about it.
>
> Those should work, but aren't a complete solution. You still need to write
> the callbacks (although if you have the ENTIRE file in memory before the
> open call, the callbacks can just return appropriate errors).
>

extern int ov_open(FILE *f,OggVorbis_File *vf,char *initial,long ibytes);

The third parameter, initial is not a const. Is this because of problems
with C or is initial being modified?

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