I’m using fmod to play streaming audio from a LAN. The delay need to be at a minimum and therefore I have reduced the buffer size of the socket to a level where the streaming callback have to wait in a blocking read a few ms before a 50 ms chunk of audio arrives.

Everything worked fine with fmod 3.4 but the 3.5 version, as it seems, can’t stand to block those ms in the callback without starting to add pop and crackle noise to the
audio. When I increase the size of the socket buffer, and make sure that there always are packets waiting to be read, the problem goes away.

What has changed in the new version ?
Can I do something about it ?

I’m running the windows version of fmod.

  • You must to post comments

Im doing something similar to this…
I get pops too.

I have a general stream question. Im using
some code from the sample2 demo(modified):

stream = FSOUND_Stream_Create(streamcallback, 16000*2, FSOUND_MONO | FSOUND_16BITS, 16000, 12345);

I have a question about the 16000*2 field.
Im trying to stream a 16khz mono stream (16 bits) which means that one second of data is 32K (16000 samples * 2 bytes a sample).
Is this value correct or too high? Im hearing pops sometimes. Maybe my data isnt coming over the socket fast enough?

Inside the callback function, I copy data from the socket memory buffer to the stereo16bitbuffer. I assume this is the right place. I ensure that there is data in the socket buffer before I copy anything.

Im using memory, not files to hold all samples. Any ideas?


  • You must to post comments
Showing 1 result
Your Answer

Please first to submit.