summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2009-10-31 03:10:00 +0100
committerLennart Poettering <lennart@poettering.net>2009-11-11 05:17:06 +0100
commitd711caa38cbe60d7776142cff0cc4aa551b89187 (patch)
treea02cd7b0823227d4d2c63fc0bca5feeb9e41cfc2
parent82d7b75528bc6cad63e5647b13877e1dcd786227 (diff)
alsa: cover Headphone2 mixer element
As seen on some drivers: https://bugzilla.redhat.com/show_bug.cgi?id=498612
-rw-r--r--src/Makefile.am1
-rw-r--r--src/modules/alsa/mixer/paths/analog-output-headphones-2.conf79
-rw-r--r--src/modules/alsa/mixer/paths/analog-output-headphones.conf4
-rw-r--r--src/modules/alsa/mixer/profile-sets/default.conf4
4 files changed, 86 insertions, 2 deletions
diff --git a/src/Makefile.am b/src/Makefile.am
index 6544e2aa..264edb5e 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -139,6 +139,7 @@ EXTRA_DIST = \
modules/alsa/mixer/paths/analog-output.conf \
modules/alsa/mixer/paths/analog-output.conf.common \
modules/alsa/mixer/paths/analog-output-headphones.conf \
+ modules/alsa/mixer/paths/analog-output-headphones-2.conf \
modules/alsa/mixer/paths/analog-output-lfe-on-mono.conf \
modules/alsa/mixer/paths/analog-output-mono.conf
diff --git a/src/modules/alsa/mixer/paths/analog-output-headphones-2.conf b/src/modules/alsa/mixer/paths/analog-output-headphones-2.conf
new file mode 100644
index 00000000..8b2968e5
--- /dev/null
+++ b/src/modules/alsa/mixer/paths/analog-output-headphones-2.conf
@@ -0,0 +1,79 @@
+# This file is part of PulseAudio.
+#
+# PulseAudio is free software; you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as
+# published by the Free Software Foundation; either version 2.1 of the
+# License, or (at your option) any later version.
+#
+# PulseAudio is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with PulseAudio; if not, write to the Free Software Foundation,
+# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
+
+; Path for mixers that have a 'Headphone2' control
+;
+; See analog-output.conf.common for an explanation on the directives
+
+[General]
+priority = 90
+
+[Element Hardware Master]
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element Master]
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element Master Mono]
+switch = off
+volume = off
+
+[Element Headphone]
+switch = off
+volume = off
+
+[Element Headphone2]
+required = any
+switch = mute
+volume = merge
+override-map.1 = all
+override-map.2 = all-left,all-right
+
+[Element Speaker]
+switch = off
+volume = off
+
+[Element Front]
+switch = off
+volume = off
+
+[Element Rear]
+switch = off
+volume = off
+
+[Element Surround]
+switch = off
+volume = off
+
+[Element Side]
+switch = off
+volume = off
+
+[Element Center]
+switch = off
+volume = off
+
+[Element LFE]
+switch = off
+volume = off
+
+.include analog-output.conf.common
diff --git a/src/modules/alsa/mixer/paths/analog-output-headphones.conf b/src/modules/alsa/mixer/paths/analog-output-headphones.conf
index 61d2e297..6e79a786 100644
--- a/src/modules/alsa/mixer/paths/analog-output-headphones.conf
+++ b/src/modules/alsa/mixer/paths/analog-output-headphones.conf
@@ -44,6 +44,10 @@ volume = merge
override-map.1 = all
override-map.2 = all-left,all-right
+[Element Headphone2]
+switch = off
+volume = off
+
[Element Speaker]
switch = off
volume = off
diff --git a/src/modules/alsa/mixer/profile-sets/default.conf b/src/modules/alsa/mixer/profile-sets/default.conf
index ac41a8d3..ffa1a4fc 100644
--- a/src/modules/alsa/mixer/profile-sets/default.conf
+++ b/src/modules/alsa/mixer/profile-sets/default.conf
@@ -62,14 +62,14 @@ auto-profiles = yes
[Mapping analog-mono]
device-strings = hw:%f
channel-map = mono
-paths-output = analog-output analog-output-headphones analog-output-mono analog-output-lfe-on-mono
+paths-output = analog-output analog-output-headphones analog-output-headphones-2 analog-output-mono analog-output-lfe-on-mono
paths-input = analog-input analog-input-mic analog-input-linein analog-input-aux analog-input-video analog-input-tvtuner analog-input-fm analog-input-mic-line
priority = 1
[Mapping analog-stereo]
device-strings = front:%f hw:%f
channel-map = left,right
-paths-output = analog-output analog-output-headphones analog-output-mono analog-output-lfe-on-mono
+paths-output = analog-output analog-output-headphones analog-output-headphones-2 analog-output-mono analog-output-lfe-on-mono
paths-input = analog-input analog-input-mic analog-input-linein analog-input-aux analog-input-video analog-input-tvtuner analog-input-fm analog-input-mic-line
priority = 10