0
0

I am playing a audio file that is being streamed over the internet using a custom file system plugin. The sound when created has the nonblocking flag enabled. So, when data is not yet available and the filesystem plugin’s read function blocks the nonblocking thread, but the streaming thread doesn’t pause and wait for the data instead it keeps playing the last couple of miliseconds that it has in its buffer, like a broken record. Is there some way for the playing thread to block until the filesystem plugin returns and the buffers are properly filled?

This other pertains to seeking within a file – when I seek from one position to another in a audio stream, it seems like the buffers do not get flushed before being filled with data from the new location. So, there is a small sound of whatever is left in the buffer is played before the sound from the new location begins to play.

  • You must to post comments
0
0

Pause or mute the sound when you get a starving flag

  • You must to post comments
Showing 1 result
Your Answer

Please first to submit.