[SDL] Real-time audio generation
mackay.pete+sdl at gmail.com
Fri Sep 19 08:58:39 PDT 2008
Really the callback provided to SDL_OpenAudio should be all you need.
I'm not sure what the problem is exactly.
Regardless, here's some pretty much bare bones code, with comments. I
won't promise that it does everything right though:
Rip out the Quake specific parts and you'll be left with an empty
callback function which you should complete to generate audio data.
Hope this helps,
2008/9/19 W.Boeke <w.boeke at chello.nl>:
> Will Langford wrote:
>> An audio buffer is an audio buffer. Just fill a given audio buffer with
>> your progmatically generated content and spit that at the audio backend.
>> different than loading sections of a large audio file bits at a time into
>> the audio backend, except you substitute your generators in place of file
> That's exactly what I did, however the result was horrible.
>> If you're fishing for documents on how to generate different waveforms and
>> stuff, ya should ask more bluntly so :)
> I'm no fisher, and generating waveforms is my speciality ;)
> Please, please 1 small, working example ....
> SDL mailing list
> SDL at lists.libsdl.org
More information about the SDL