I’m having a problem working with streams, as FMOD refuses to play my IMA ADPCM sounds if I specify, at stream creation time, that the format is FMOD_SOUND_FORMAT_IMAADPCM. Below is my code (based on the real time stitching example), and unless I set the format to PCM16 no sound is played (it does play my IMA sounds, but only if the format is set to PCM16). I’ve also found that if I substitute any of the sounds on the PlaySound example by an IMA ADPCM and then I query FMOD about the sound format, it will always return PCM16, even though it’s playing an IMA ADPCM.

Thanks in advance for any clarification on this

[code:1q1efpz4] memset(&exinfo, 0, sizeof(FMOD_CREATESOUNDEXINFO));
exinfo.cbsize = sizeof(FMOD_CREATESOUNDEXINFO);
exinfo.defaultfrequency = 24000;
exinfo.numsubsounds = 2;
exinfo.numchannels = 2;

// Create sound stream
result = system->createStream(NULL, FMOD_LOOP_NORMAL | FMOD_OPENUSER | FMOD_ACCURATETIME | FMOD_SOFTWARE, &exinfo, &sound);[/code:1q1efpz4]

  • You must to post comments

Through exinfo you are defining the sample that will be played, the format will be PCM16 because that’s what the stream is decoding it as. FMOD_SOUND_FORMAT_IMAADPCM is used when you load the data compressed into the sample for FMOD_CREATECOMPRESSEDSAMPLE playback.

  • You must to post comments
Showing 1 result
Your Answer

Please first to submit.