SDL_PauseAudio(0) & audio_callback( )

Hi,
I’d like to understand relation between SDL_PauseAudio and its
audio_callback(void *userdata, Uint8 *stream, int len) implicit function.

When SDL_PauseAudio(0) call audio_callback implicitly,
What’s the “len” value?
Where does the “len” value change?

Many thanks in advance for your support.
Regards. Rona.

Rona wrote:

Hi,
I’d like to understand relation between SDL_PauseAudio and its
audio_callback(void *userdata, Uint8 *stream, int len) implicit function.

When SDL_PauseAudio(0) call audio_callback implicitly,
What’s the “len” value?
Where does the “len” value change?

You should’t worry about predictiing the “len” value. SDL asks you for a
given size of audio data, you should feed it the requested size, no
more, no less.
If you assume changes/no changes with “len”, you’re writing non portable
code (or you’re doing some nice unintended audio effects :). “len” of
course has such patterns, but these are highly context and platform
dependent, as you see.

Stephane