[Speex-dev] Sample code for streaming from a file

Conrad Parker conrad at metadecks.org
Wed Dec 26 00:22:36 PST 2007


Hi Vince,

if you want a callback-based API you can use libfishsound, which wraps
libspeex. An example playback application is:

http://www.annodex.net/software/libfishsound/html/group__decode.html

cheers,

Conrad.

On 26/12/2007, Vince Tagle <vtagle at gmail.com> wrote:
> It's not by much but the little piece of the puzzle I haven't been
> able to figure out is how to write the function that will read out a
> small chuck, process it, and then exit. This function would then be
> called continuously to process another small chunk when the previous
> chunk is done playing. I've already tried separating out that bit of
> code in speexdec to no avail.
>
> It's entirely possible that the code I've written so far is doing all
> of that correctly and the error is somewhere else but I'd like to
> hear from people that have done this already so I can figure out what
> I'm doing wrong.
>
> Vince Tagle
> <vtagle at gmail.com>
>
> On Dec 25, 2007, at 12:55 AM, Jean-Marc Valin wrote:
>
> > How's that different from speexdec?
> >
> >       Jean-Marc
> >
> > Vince Tagle a écrit :
> >> Hello,
> >>
> >> Does anyone have any sample code for opening up a speex file and
> >> streaming the data from it over time? I've been wrestling with
> >> this for
> >> a couple days now, poring over other people's code but I can't
> >> find an
> >> example of just taking a chunk from the file, decoding it, and
> >> feeding
> >> it to a sound API (in my case, OpenAL) and then repeating until done.
> >>
> >> Vince Tagle
> >> <vtagle at gmail.com>
> >>
> >> _______________________________________________
> >> Speex-dev mailing list
> >> Speex-dev at xiph.org
> >> http://lists.xiph.org/mailman/listinfo/speex-dev
> >>
> >>
>
> _______________________________________________
> Speex-dev mailing list
> Speex-dev at xiph.org
> http://lists.xiph.org/mailman/listinfo/speex-dev
>
>


More information about the Speex-dev mailing list