[Gllug] What's a sound server?

Nix nix at esperi.org.uk
Fri Jun 13 09:40:41 UTC 2008


On 12 Jun 2008, salsaman at xs4all.nl stated:
> I am not overly familiar with pulseaudio, but I know a little about sound
> servers. Their purpose is mainly to take audio in from various inputs, mix
> them, and then route the result to various outputs. Usually they also
> provide sync to the various inputs and outputs - letting these programs
> know when they can send or receive another audio buffer. Generally having
> a sound server running makes life easier for application programmers
> because it also abstracts away a lot of the low level stuff.

Note that the `inputs' and `outputs' may be networkologically remote (PA
can stream via RTSP, its own protocol, and so on).

That's what I use it for: it doesn't matter which machine in my house
generates sound, it all comes out of the same set of speakers.

> I believe pulseaudio is similar to jack but intended more for desktop
> users (the jack developers are aiming for high-end audio).

Not really but then sort of. PA's most important job is to *cut out the
crap*. There are a whole pile of existing sound servers (esd and alsa
being the most infamous) and they all *suck*: they're latency-filled laggy
piles of slow insecure buggy stealing-your-soundcard crap, and they all
have different protocols and programming interfaces, and none of them
interoperate.

PA can pretend to be esd, can sit behind ALSA as a plugin, can to some
degree pretend to be OSS, can communicate via the ESD network protocol,
mixes sound from multiple sources together so that you don't have one app
stealing your soundcard anymore, and can generally replace the mess that
is Linux sound with something less horrendous.

Also it's extensible and written in a non-vile fashion (as much as that is
possible with current ALSA APIs) so it probably won't fall into the same
unmaintained state as all the *other* sound servers.

> Regarding your soundcard not working, I doubt it has anything to do with
> lack of a sound server. You should be able to play back audio using alsa -
> the sound server will use normally use alsa itself for output.

(PA can also use OSS, but ALSA is preferred.)

Note that GNOME and KDE apps, at least, require a sound server before they'll
emit any sound. They normally start it by default but often this doesn't work
(see above re existing sound servers sucking).

> - try playing back audio without the desktop running (for example using
> mpg123 or ogg123)

Good test, but note that mpg123 has lots of output drivers these days,
so try using `--output alsa' to force it to avoid using any sound
servers :)

-- 
`If you are having a "ua luea luea le ua le" kind of day, I can only
 assume that you are doing no work due [to] incapacitating nausea caused 
 by numerous lazy demons.' --- Frossie
-- 
Gllug mailing list  -  Gllug at gllug.org.uk
http://lists.gllug.org.uk/mailman/listinfo/gllug




More information about the GLLUG mailing list