QUOTE (Ranguvar @ Sep 9 2009, 09:33 PM)

Hold on there, Rod. It sounds like you've been away from Linux for a bit?
No. I've got seven Linux installations on five computers. Some of these I've deliberately left running somewhat old distributions, but others are quite recent (Fedora 11, for instance). I consult and write about Linux for a living.
QUOTE
It sounds like you're describing the old OSS, OSS3. For the uninitiated, OSS3 was pretty much the universal sound API across all Unices (except likely OS X). Then came OSS4, which was closed source. Forced to choose between forking OSS and creating a new sound API, the Linux hackers chose the new route, and created ALSA (IMHO, a mistake, but then I am no kernel hacker). Basically _any_ distro you run across today uses ALSA.
Yes and no. Every modern distribution supports ALSA, to one extent to another. Part of the problem is that ALSA provides an OSS emulation layer, and many individual programs and sound libraries use that layer, which causes contention issues. It must also be emphasized that a phrase such as "any distro... uses ALSA" is misleading, because the sound picture in Linux is
not unified. Program A might use ALSA, Program B might use OSS (or at least the OSS device files provided by ALSA), Program C might use a library that can be configured to use either ALSA or OSS, and Program D might be configurable to use ALSA directly, OSS directly, or another library (other than the one that Program C uses). You can see that this is a mess.
QUOTE
Some provide another system on top of ALSA, PulseAudio.
When I first heard of PulseAudio, I nearly screamed: It was yet another library that was further complicating the already complex Linux audio system. PulseAudio is just one of the "about a million different libraries" to which I referred in my original post. There are lots of others, such as ESD (PulseAudio's predecessor), SDL, etc. Some libraries are even built atop other libraries.
It's been a while since I've looked into the details, but clearly some programs and libraries still use the OSS devices, which can accept just one input (even when it's ALSA that handles the sound hardware). The result is that no other application can play sounds. For instance, when I run the QEMU emulator binary that's provided by Ubuntu with its 8.04 release, OSes run in the emulator can play sounds fine -- but suddenly my Konsole terminals can't produce beeps. I recently recompiled QEMU from source for other reasons, and I discovered a sound option. When I enabled ALSA support and disabled all the other audio options (there are
six in total for QEMU!), my new binary no longer hogged the sound card.
QUOTE
It should be noted for accuracy that OSS4 has since been open-sourced again. There seem to be no plans to merge OSS4 into the kernel, BUT, there are ways to replace ALSA and PulseAudio with OSS4 (OSS4 covers both ALSA and PulseAudio's functions) in most distros. Completely unsupported, of course. OSS4 has problems for me, otherwise I'd be using it right now.
As of the 2.6.30 kernel, the OSS drivers are marked as "deprecated," meaning their use is discouraged and they may be removed. This isn't an area I follow all that closely, though, so I don't know what the kernel developers might be planning for the future. Certainly the OSS drivers have been marked as deprecated for quite a while.
QUOTE
The above is a VERY simplified picture of Linux sound, and may be inaccurate. While I LOVE Linux, I must agree with Rob -- sound on Linux is a tangled mess. It's one of the weak spots. Hopefully we will very soon be at the point where Joe Ubuntu won't have to know anything about the underpinnings of Linux sound (_maybe_ we're there already), but for the foreseeable future, heavy power users and especially developers will be headdesking over Linux sound.
Casual and productivity (word processing, etc.) users can probably get by without knowing too much; sound does
mostly work on Linux, and this is enough for most productivity uses of an OS. The problems come when you rely on sound (say, a sound being played to announce the arrival of new e-mail) and/or when you use audio-heavy programs (games, video playback, etc.).
Some such programs can interfere with one another, and figuring out why can be difficult.
Unfortunately, I'm less optimistic than you are about this. The sound situation in Linux has been a mess for a decade, and it's gotten more messy over that time, not less messy. Part of the mess is because so many Linux programs aren't really Linux programs -- they're Unix programs, intended to run on multiple platforms (Linux, FreeBSD, Solaris, etc.). Some also run on Windows, Mac OS, and perhaps even other OSes. This makes it hard to simplify the tangled mess by eliminating libraries or sound subsystems, since no one access method can be used across all these different platforms. Instead, new libraries seem to pop up to deal with new needs, such as thin client audio.
Don't get me wrong; I like Linux. It's my everyday-use OS. Its handling of sound is arguably its weakest point, though, at least from a desktop user point of view.