[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
03/03: doc: Add an example of ~/.asoundrc file for ALSA configuration.
From: |
??? |
Subject: |
03/03: doc: Add an example of ~/.asoundrc file for ALSA configuration. |
Date: |
Mon, 25 Jun 2018 11:30:11 -0400 (EDT) |
iyzsong pushed a commit to branch master
in repository guix.
commit 6d91a4699254e0bf15e8bf5968c0b542d1b69f38
Author: 宋文武 <address@hidden>
Date: Mon Jun 25 22:23:24 2018 +0800
doc: Add an example of ~/.asoundrc file for ALSA configuration.
* doc/guix.texi (Sound Services): Improve it and add an example of
~/.asoundrc
file.
---
doc/guix.texi | 52 ++++++++++++++++++++++++++++++++++++++++++++--------
1 file changed, 44 insertions(+), 8 deletions(-)
diff --git a/doc/guix.texi b/doc/guix.texi
index e5366ac..da05a20 100644
--- a/doc/guix.texi
+++ b/doc/guix.texi
@@ -13131,15 +13131,15 @@ Users need to be in the @code{lp} group to access the
D-Bus service.
@cindex ALSA
@cindex PulseAudio, sound support
-The @code{(gnu services sound)} module provides an
address@hidden service to generate an ALSA
address@hidden/etc/asound.conf} configuration file. This configuration file is
-what allows applications that produce sound using ALSA to be correctly
-handled.
+The @code{(gnu services sound)} module provides a service to configure the
+Advanced Linux Sound Architecture (ALSA) system, which making PulseAudio the
+prefered ALSA output driver.
@deffn {Scheme Variable} alsa-service-type
-This is the type for the @uref{https://alsa-project.org/, ALSA},
address@hidden record as in this example:
+This is the type for the @uref{https://alsa-project.org/, Advanced Linux Sound
+Architecture} (ALSA) system, which generates the @file{/etc/asound.conf}
+configuration file. The value for this type is a @command{alsa-configuration}
+record as in this example:
@example
(service alsa-service-type)
@@ -13164,11 +13164,47 @@ at the same time and to individual control them
@i{via}
@command{pavucontrol}, among other things.
@item @code{extra-options} (default: @var{""})
-String to append to the @file{asound.conf} file.
+String to append to the @file{/etc/asound.conf} file.
@end table
@end deftp
+Individual users who want to override the system configuration of ALSA can do
+it with the @file{~/.asoundrc} file:
+
address@hidden
+# In guix, we have to specify the absolute path for plugins.
+pcm_type.jack @{
+ lib "/home/alice/.guix-profile/lib/alsa-lib/libasound_module_pcm_jack.so"
address@hidden
+
+# Routing ALSA to jack:
+# <http://jackaudio.org/faq/routing_alsa.html>.
+pcm.rawjack @{
+ type jack
+ playback_ports @{
+ 0 system:playback_1
+ 1 system:playback_2
+ @}
+
+ capture_ports @{
+ 0 system:capture_1
+ 1 system:capture_2
+ @}
address@hidden
+
+pcm.!default @{
+ type plug
+ slave @{
+ pcm "rawjack"
+ @}
address@hidden
address@hidden example
+
+See @uref{https://www.alsa-project.org/main/index.php/Asoundrc} for the
+details.
+
+
@node Database Services
@subsubsection Database Services