mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2026-04-17 06:46:24 -04:00
ACP was re-selecting the “best” port on every port availability event, even when a port was already explicitly selected by the user. This differs from PulseAudio’s behavior, where port switching decisions are left to higher-level policy. This caused issues on devices where Line Out (speakers) and Headphones share the same analog interface: when headphones are plugged in, ACP would immediately switch away from the user-selected Line Out, or end up in a state where no sound is produced despite selecting speakers explicitly from clients like pwvucontrol. Fix this by only re-evaluating and switching ports when: - no active port is currently selected, or - the active port has become unavailable This preserves manual user choices and prevents ACP from fighting client port selections during route activation. Additionally, adjust ALSA mixer paths to better separate Line Out and Headphones behavior: - Disable Line Out controls in the headphones path - Add explicit Line Out and Auto-Mute Mode handling in the lineout path Together, these changes align PipeWire’s behavior more closely with PulseAudio and fix cases where selecting speakers while headphones are plugged results in no audio output. Signed-off-by: John Titor <masumrezarock100@gmail.com>
227 lines
4.3 KiB
Text
227 lines
4.3 KiB
Text
# 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, see <http://www.gnu.org/licenses/>.
|
|
|
|
[General]
|
|
priority = 90
|
|
description-key = analog-output-lineout
|
|
|
|
[Jack Line Out]
|
|
required-any = any
|
|
|
|
[Jack Line Out Phantom]
|
|
state.plugged = unknown
|
|
state.unplugged = unknown
|
|
required-any = any
|
|
|
|
[Jack Front Line Out]
|
|
required-any = any
|
|
|
|
[Jack Front Line Out Phantom]
|
|
state.plugged = unknown
|
|
state.unplugged = unknown
|
|
required-any = any
|
|
|
|
[Jack Rear Line Out]
|
|
required-any = any
|
|
|
|
[Jack Rear Line Out Phantom]
|
|
state.plugged = unknown
|
|
state.unplugged = unknown
|
|
required-any = any
|
|
|
|
[Jack Line Out Front]
|
|
required-any = any
|
|
|
|
[Jack Line Out Front Phantom]
|
|
state.plugged = unknown
|
|
state.unplugged = unknown
|
|
required-any = any
|
|
|
|
[Jack Line Out CLFE]
|
|
state.plugged = unknown
|
|
state.unplugged = unknown
|
|
required-any = any
|
|
|
|
[Jack Line Out CLFE Phantom]
|
|
state.plugged = unknown
|
|
state.unplugged = unknown
|
|
required-any = any
|
|
|
|
[Jack Line Out Surround]
|
|
state.plugged = unknown
|
|
state.unplugged = unknown
|
|
required-any = any
|
|
|
|
[Jack Line Out Surround Phantom]
|
|
state.plugged = unknown
|
|
state.unplugged = unknown
|
|
required-any = any
|
|
|
|
[Jack Line Out Side]
|
|
state.plugged = unknown
|
|
state.unplugged = unknown
|
|
required-any = any
|
|
|
|
[Jack Line Out Side Phantom]
|
|
state.plugged = unknown
|
|
state.unplugged = unknown
|
|
required-any = any
|
|
|
|
[Jack Dock Line Out]
|
|
required-any = any
|
|
|
|
[Jack Dock Line Out Phantom]
|
|
state.plugged = unknown
|
|
state.unplugged = unknown
|
|
required-any = any
|
|
|
|
[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 Speaker+LO]
|
|
switch = mute
|
|
volume = merge
|
|
override-map.1 = all
|
|
override-map.2 = all-left,all-right
|
|
required-any = any
|
|
|
|
[Element Headphone+LO]
|
|
switch = mute
|
|
volume = merge
|
|
override-map.1 = all
|
|
override-map.2 = all-left,all-right
|
|
required-any = any
|
|
|
|
[Element Line Out]
|
|
switch = mute
|
|
volume = merge
|
|
override-map.1 = all
|
|
override-map.2 = all-left,all-right
|
|
|
|
[Element Master Mono]
|
|
switch = off
|
|
volume = off
|
|
|
|
; Prefer manual routing decisions by disabling codec auto-mute here.
|
|
[Element Auto-Mute Mode]
|
|
enumeration = select
|
|
|
|
[Option Auto-Mute Mode:Disabled]
|
|
name = analog-output-lineout
|
|
|
|
[Element Line HP Swap]
|
|
switch = off
|
|
required-any = any
|
|
|
|
; This profile path is intended to control line out, let's mute headphones
|
|
; else there will be a spike when plugging in headphones
|
|
[Element Headphone]
|
|
switch = off
|
|
volume = off
|
|
|
|
[Element Headphone,1]
|
|
switch = off
|
|
volume = off
|
|
|
|
[Element Headphone2]
|
|
switch = off
|
|
volume = off
|
|
|
|
[Element Speaker]
|
|
switch = off
|
|
volume = off
|
|
|
|
[Element Desktop Speaker]
|
|
switch = off
|
|
volume = off
|
|
|
|
[Element Front]
|
|
switch = mute
|
|
volume = merge
|
|
override-map.1 = all-front
|
|
override-map.2 = front-left,front-right
|
|
|
|
[Element Rear]
|
|
switch = mute
|
|
volume = merge
|
|
override-map.1 = all-rear
|
|
override-map.2 = rear-left,rear-right
|
|
|
|
[Element Surround]
|
|
switch = mute
|
|
volume = merge
|
|
override-map.1 = all-rear
|
|
override-map.2 = rear-left,rear-right
|
|
|
|
[Element Side]
|
|
switch = mute
|
|
volume = merge
|
|
override-map.1 = all-side
|
|
override-map.2 = side-left,side-right
|
|
|
|
[Element Center]
|
|
switch = mute
|
|
volume = merge
|
|
override-map.1 = all-center
|
|
override-map.2 = all-center,all-center
|
|
|
|
[Element LFE]
|
|
switch = mute
|
|
volume = merge
|
|
override-map.1 = lfe
|
|
override-map.2 = lfe,lfe
|
|
|
|
[Element CLFE]
|
|
switch = mute
|
|
volume = merge
|
|
override-map.1 = all-center
|
|
override-map.2 = all-center,lfe
|
|
|
|
[Element Center/LFE]
|
|
switch = mute
|
|
volume = merge
|
|
override-map.1 = all-center
|
|
override-map.2 = all-center,lfe
|
|
|
|
[Element Bass Speaker]
|
|
switch = off
|
|
volume = off
|
|
|
|
[Element Speaker Front]
|
|
switch = off
|
|
volume = off
|
|
|
|
[Element Speaker Surround]
|
|
switch = off
|
|
volume = off
|
|
|
|
[Element Speaker Side]
|
|
switch = off
|
|
volume = off
|
|
|
|
[Element Speaker CLFE]
|
|
switch = off
|
|
volume = off
|
|
|
|
.include analog-output.conf.common
|