Firstly. fmod is a very good tool. 😀
I used Mircosoft’s avi API to gain a buffer point. I am sure that I can gain correct buffer which point to the audio data by those code as below:
char *pBuffer = new char[lsize];
But I can’t gain the point to point to the stream datea as below codes: the result is “spaud = NULL”,
spaud = FSOUND_Stream_OpenFile(pBuffer,FSOUND_NORMAL|FSOUND_LOADMEMORY,lSize);
Can some one help me? or give me an another idear to play the avi audio? I highly appreciate your help!
- SoundlessAir asked 14 years ago
You raise a good idea for working around the interleaved audio limitation in FMOD. I hope you eventually figure it all out I’m only casually familiar with the avifil32 library, having used a few of the basic functions.
So, you’ve called AVIFileOpen and then AVIGetStream (using streamType 1935963489) to get an interface to the audio stream. Are you also calling AVIStreamBeginStreaming before using AVIStreamRead?
Let me know if you make any progress,
- stdev answered 14 years ago
hi ,thanks brett very much! 😀
you certainly help me to fixed this problem… i am excited to hear nice muisc from speaker…. 😀 some code is below:
spaud = FSOUND_Stream_OpenFile(pBuffer, FSOUND_LOADRAW | FSOUND_8BITS | FSOUND_MONO | FSOUND_UNSIGNED|FSOUND_LOADMEMORY, lSize);
But ..the sound is played faster than avi video…
I used function FSOUND_Stream_SetTime to reduce the playing velocity in each frame…..
int interval = 15;
FSOUND_Stream_SetTime(spaud, FSOUND_Stream_GetTime(spaud)+ interval );
the playing velocity will decrease along with the value of interval decrease… but the effect is bad …sound is incontinuous….. 😀
brett ,Could you give me some good idear to solve this problem…thanks again……
Please login first to submit.