This is an old revision of the document!


The linux audio stack has several layers. This page will give a brief overview over each layers' capabilities and responsibilities.

Kernel layer

The most low-level layer is the kernel layer, which takes care of the communication with the hardware. This role is usually fulfilled by ALSA or OSS.

Most sound cards do not support 'hardware mixing', meaning each output can only play one stream at a time. This is, of course, inconvenient: you might want to play sounds from more applications at a time. Mixing is one of the most important operations performed by the higher-level layers.

If you're experiencing problems with the soundcard being locked, see Finding out which application is holding your sound card

ALSA userspace

On top of the kernel ALSA layer, ALSA also provides some user-space plugins, including mixing with Dmix.

Sound servers

On top of the layers mentioned so far, there are several 'sound servers' that perform some more advanced functions.

Jack

JACK is the standard sound server for audio production work.

PulseAudio, ESounD, GStreamer, aRts

Other sound servers such as PulseAudio, EsounD, GStreamer and aRts serve various desktop audio needs, and have lots of overlapping functionality, but are not specifically focused towards audio production like JACK.

Compatibility layers

An application that does not use a sound server is generally written for either OSS (in which case it would use /dev/dsp*) or ALSA (in which case it would use /dev/snd/* though the ALSA libraries).

This would mean OSS would not work on systems using ALSA and vice-versa. Luckily, both projects provide a 'compatibility layer' to work with each others' applications.

wiki/audio_layers_overview.1259012572.txt.gz ยท Last modified: 2009/11/23 22:42 by lee