0
0

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:

PAVISTREAM paud;
char *pBuffer = new char[lsize];

AVIStreamRead( paud,AVIStreamStart(paud),AVISTREAMREAD_CONVENIENT,pBuffer,lSize,NULL,NULL);

:( But I can’t gain the point to point to the stream datea as below codes: the result is “spaud = NULL”,

FSOUND_STREAM* spaud;
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!
ww-yy@tom.com

  • You must to post comments
0
0

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,

  • SD
  • You must to post comments
0
0

hi, stdv and brett, thanks for reply! :)

but I hadn’t resoluved this problem yet…. ๐Ÿ˜ฅ

the data format of the avi audio is PCM with 8 Bits samplesize…and 176kbps

  • You must to post comments
0
0

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……

  • You must to post comments
Showing 3 results
Your Answer

Please first to submit.