Not logged in
Log in now
Create an account
Subscribe to LWN
LWN.net Weekly Edition for May 23, 2013
An "enum" for Python 3
An unexpected perf feature
LWN.net Weekly Edition for May 16, 2013
A look at the PyPy 2.0 release
Posted Oct 7, 2009 21:12 UTC (Wed) by drag (subscriber, #31333)
PulseAudio is portable also. It runs on Alsa/OSS/Windows/OSX/ blah blah blah. But I think for what your asking you'd have better luck with Gstreamer.
If you target Alsa then you can use the 'safe' subset that is supported by PulseAudio then you might be fine. It's possible to port the 'safe' parts of the libasound to other platforms, but what a pain.
You could target SDL and get cross platform compatibility, but that is mostly for game makers.
If you target full Alsa then that is Linux-only. If you OSS then that means it's only useful on some of the BSDs and possibly Solaris.
Posted Oct 7, 2009 21:31 UTC (Wed) by ncm (subscriber, #165)
Posted Oct 8, 2009 12:25 UTC (Thu) by nye (guest, #51576)
Not so much - because it's only technically true (in other words, it's lies). A couple of years ago they managed to build it on a selection of platforms so they could claim 'portability' as a ticklist item.
Try building PulseAudio for Windows. When you've given up, try installing the binary package that is usually mentioned whenever this discussion comes up - it's two years old and I couldn't get it to work *at all* with a few hours' hair-pulling.
I don't know where the OS X idea came from - PA doesn't even *claim* to work there, and according to the PA website, the last time it was tested on anything other than Linux was 2007.
Posted Oct 7, 2009 22:10 UTC (Wed) by ncm (subscriber, #165)
Posted Oct 7, 2009 22:43 UTC (Wed) by drag (subscriber, #31333)
Posted Oct 8, 2009 12:09 UTC (Thu) by nix (subscriber, #2304)
Posted Oct 14, 2009 12:15 UTC (Wed) by pharm (guest, #22305)
If you target Alsa then you can use the 'safe' subset that is supported by PulseAudio then
might be fine.
The (slightly abrasive, but ultimately useful) discussion on the Braid blog about audio
Linux eventually revealed that the safe Alsa subset isn't really a great deal of use, because you
guarantee to get your hands on the audio ring buffer & rewrite the parts that haven't been
yet on the fly: The alsa mmap functions that let you do this aren't part of the safe core :(
The *biggest* issue that arose from that discussion was that it's well nigh on impossible for
developer to work out what they're expected to use if they need more than the basic SDL sound
(which can't do a great deal more than 'play this sound now please'). The safe ALSA subset plus
mmap alsa functions (since most hardware can expose those in reality) is probably it, but that
Posted Oct 20, 2009 9:32 UTC (Tue) by njs (guest, #40338)
A better API is clearly needed, but I don't think it involves mmap.
Posted Oct 20, 2009 10:57 UTC (Tue) by cladisch (✭ supporter ✭, #50193)
Classic mmap() can't. However, the ALSA API requires that the applications tells when and where it wants to access the buffer, and when it is done, so it is possible to emulate mmap on top on devices without a memory buffer. (In that case, the extra buffer adds latency, of course.)
> A better API is clearly needed
ALSA has snd_pcm_forward/rewind functions to move around in the buffer. However, these functions are optional, and the PulseAudio plugin does not implement them.
Gstreamer and codecs
Posted Oct 7, 2009 21:19 UTC (Wed) by dmarti (subscriber, #11625)
Copyright © 2013, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds