[Openal] playing a raw buffer
Chris Robinson
chris.kcat at gmail.com
Wed Apr 22 18:22:45 PDT 2009
On Wednesday 22 April 2009 11:50:53 am gmail wrote:
> My program anyway have still another source.
>
> The problem is that, strange things happen: sometimes the raw file
> buffer is played fine, sometimes, if i play it after have used the other
> source, it start to be played from half of its' size. Some time it is
> not played at all.
>
> I am quite sure i am using a bad approach,
> any help is really appreciated.
Hi.
What OS/lib version are you using? The main thing I can think to look for is,
if the file stream opened and used previously you should reset it to the
beginning before starting to read it. It may help to post more of the source
that's giving problems, because nothing immediately strikes me as wrong from
what you posted.
And as a side note, from that code snippet, the OpenAL buffer isn't being
deleted (make sure to do it after the source). :)
More information about the Openal
mailing list