0
0

Hi,
I trying to play avi file.
I’m using this code to play sound from audio stream :

memset(&exinfo, 0, sizeof(FMOD_CREATESOUNDEXINFO));
exinfo.cbsize = sizeof(FMOD_CREATESOUNDEXINFO);
exinfo.length = buffersize;//stream_info.dwScale;
result=FMOD_System_CreateStream(sys, (const char
) m_lpAudioBuffer, FMOD_OPENMEMORY, &exinfo, &sound);

  eBook("exinfo.length is %d",exinfo.length);
  ERRCHECK(result);
  FMOD_System_PlaySound(sys, FMOD_CHANNEL_FREE, sound, 0, &channel); 

Sometimes it works fine, BUT sometimes it doesn’t want. I think it’s a problem from the format tag 0x55, but I can’t find out the solution.
The first file is playing nicely, but the second one doesn’t.
I don’t understand the thing, that the two files files played good on fmod 3 and not on fmodEx

16 – File : C:/My Shared Folder\Clips\Clip-Benabar – Dis Lui Oui.avi
16 – lSize 30.
16 – AviStreamReadFormat
16 – Scale is 1
16 – Rate is 16000
16 – Start is 0
16 – Length is 3237341
16 – Audio skew is 0
16 – SuggestedBufferSize is 8000
16 – dwSampleSize is 1
16 – Format tag is 0 x 55
16 – Number of channels are 2
16 – Bits per sample are 0
16 – Samples per second are 48000
16 – Average bytes per second are 16000
16 – Block Align is 1
16 – CB size is 12
16 – Frame End is 3237341.
16 – Sample to time is 12646.
16 – right is 0.
16 – left is 0.
16 – top is 0.
16 – bottom is 0.
16 – buffersize 3237341.
16 – lSize 3237341.
16 – AVI 0.000000
16 – exinfo.length is 3237341
This one works
18 – OpenAvi lancé
18 – File : C:/My Shared Folder\Clips\Natalia Imbruglia – Torn.AVI
18 – lSize 30.
18 – AviStreamReadFormat
18 – Scale is 1024
18 – Rate is 32220
18 – Start is 0
18 – Length is 14267
18 – Audio skew is 1
18 – SuggestedBufferSize is 2048
18 – dwSampleSize is 1024
18 – Format tag is 0 x 11
18 – Number of channels are 2
18 – Bits per sample are 4
18 – Samples per second are 32000
18 – Average bytes per second are 32220
18 – Block Align is 1024
18 – CB size is 2
18 – Frame End is 14267.
18 – Sample to time is 453426.
18 – right is 0.
18 – left is 0.
18 – top is 0.
18 – bottom is 0.
18 – buffersize 14609408.
18 – lSize 14267.
18 – AVI 0.000000
18 – exinfo.length is 14609408
18 – FMOD error! (25) Unsupported file or audio format.

thanks for your response

  • You must to post comments
0
0

After checking, I find out, with GSPOT, that the files who doesn’t work were VBR MP3, and the CBR LP3 were working….

Does anyone could help me understand!!

  • You must to post comments
Showing 1 result
Your Answer

Please first to submit.