[SDL] Why does this click?
Peter Mulholland
darkmatter at freeuk.com
Tue Feb 28 12:08:25 PST 2006
Hello Giles,
Tuesday, February 28, 2006, 7:46:19 PM, you wrote:
GC> Hiya,
GC> I've used SDL audio in the past, and not had problems, but I've been staring
GC> at this code for hours, and can't work out why on earth it's clicking! It
GC> should just play a sine wave. My machine is a dual core P4, so I doubt it's
GC> a CPU issue. Anyone who spots the probably obvious mistake, please yell
GC> loudly at me :-)
<snip>
Why are you calling SDL_MixAudio() ?
In the mix callback, you should fully fill whatever buffer you're
given, in other words, fill stream with up to len samples. If you
don't, you'll be sending blank data to the card to play.
--
Best regards,
Peter mailto:darkmatter at freeuk.com
More information about the SDL
mailing list