PulseAudio
From openSUSE
PulseAudio is a networked sound server that allows software mixing of audio. See the PulseAudio website for more details.
It provides:
- Software mixing of multiple audio streams, bypassing any restrictions the hardware has.
- Network transparency, allowing an application to play back or record audio on a different machine than the one it is running on.
- Sound API abstraction, alleviating the need for multiple backends in applications to handle the wide diversity of sound systems out there.
- Generic hardware abstraction, giving the possibility of doing things like individual volumes per application.
PulseAudio comes with many plugin modules. All audio from/to clients and audio interfaces goes through modules. PulseAudio clients can send audio to "sinks" and receive audio from "sources". A client can be GStreamer, xinelib, MPlayer or any other audio application. Only the device drivers/audio interfaces can be either sources or sinks (they are often hardware in- and out-puts).
Contents |
Configuration
Starting with openSUSE 11.0 pulseaudio is used for GNOME installations. By default the daemon is automatically started if an application tries to use pulseaudio. This makes it a source of problems given the wide range of sound systems/applications being used in multimedia applications. That's why if you are having issues with PulseAudio, before reporting them to our Bugzilla, make sure you read this article about the perfect PulseAudio setup. It contains information about making all available sound systems use PulseAudio for the actual sound playing.
Packages
GNOME installations include all necessary tools and packages by default. In other enviroments pulseaudio is often dragged in due to dependencies but without the tools to control it. Therefore the following packages may need to be manually installed in order to control the pulseaudio daemon:
- pavucontrol - PulseAudio Volume Control
- paprefs - PulseAudio Preferences
- pulseaudio-utils - PulseAudio utilities
- padevchooser - PulseAudio Device Chooser
- paman - PulseAudio Manager
- alsa-plugins-pulse (-32bit) - Pulseaudio Plug-In for the ALSA Library
Using Pulseaudio as alsa back-end by default
To make all applications that support alsa but not pulseaudio to play sound via pulseaudio you need to install alsa-plugins-pulse (as well as the 32bit package if you are on 64bit) and set the following environment variable:
export ALSA_CONFIG_PATH=/etc/alsa-pulse.conf
openSUSE 11.2, KDE 4.2
Pulseaudio is not used as default sound server. Run as root:
setup-pulseaudio --enable
to make it default.
In a GNOME session this variable is set by default.
Disabling Pulseaudio autospawn
Due to dependencies it is often not possible to uninstall pulseaudio completely. To prevent use of pulseaudio nevertheless autostarting the daemon can be prevented by setting autospawn = no in /etc/pulse/client.conf
Issues
5.1 Sound
There were issues getting 5.1 sound working out of the box, see bug 381686 for more information. Many people have a surround card, but have speakers for just two channels, so PulseAudio can't really default to a surround setup. To enable all the channels, edit /etc/pulse/daemon.conf: uncomment the default-sample-channels line (i.e. remove the semicolon from the beginning of the line) and set the value to 6 if you have a 5.1 setup, or 8 if you have 7.1 setup etc. Or even easier, you can run paprefs and set the speaker setup via the paprefs GUI.
Glitches in audio playback
Edit /etc/pulse/daemon.conf: uncomment the default-fragments and default-fragment-size-msec, and change values from the default 4 and 25 to 16 and 21.
Please report back in bug 381686if this works or not for you.
Returning to esound
Remove all pulseaudio* packages and install esound.
Crackling Sound with OpenAL (=Games)
The alsa plugin that forces applications to use pulseaudio often causes low sound quality in games that use OpenAL for sound output. Up to and including openSUSE 11.1 openal-soft did not support puseaudio natively. To fix sound in games either get rid of pulseaudio or install a backport from Factory
See Also
- Development page on PulseAudio Integration into openSUSE 11.0
- PulseAudio website

