SDL info update & Sound paradigms
njh at cs.monash.edu.au
njh at cs.monash.edu.au
Tue May 5 00:44:37 PDT 1998
On Mon, 4 May 1998, Sam Lantinga wrote:
> (I'm working on about three things at once here...)
>
> Okay, X11 SDL is rock solid, and no longer uses semaphores by default.
Woo Hoo! Ok, where can I get it?
> Okay, I've been working on porting code which was given to me... njh... :)
I don't know what you're talking about... :-| (<--- that is my best poker
face!)
> There's a basic problem between my idea of sound mixing and that program.
> SDL uses a periodic callback to mix a relatively small chunk of sound
> (~46 ms worth), while this program queries the audio DMA position at each
> frame, and mixes the next 100 ms or so.
>
> The problem is, this is completely incompatible with BeOS and Solaris.
> Linux has some hacks to get at the DMA buffer, and Win32 emulates it.
Yeah, but, like these are going to work on linuxppc :-)...
> Is this a very common way to write a mixer? It makes sense, but is
> tough to implement without emulation on some platforms.
Yeah, it seems that the only really good audio stuff requires practically
direct access to the hardware. Oh for a decent DSP standard...
> The alternative is to write code that mixes the audio directly, based
> on the state of the application, at the time the audio driver requests
> it, instead of mixing the next frame or two every update.
This would be better, if you can guarantee service.
njh
More information about the SDL
mailing list