pipewire/spa
Pauli Virtanen da2cecf074 alsa: acp: don't disable dB if negative max unless range is small
Disabling dB volumes for max_dB < 0 was added in Pulseaudio in 2021,
based on a device which had -128..-127.07 range. However, negative
max_dB is valid value for USB devices, and there are devices that have
it.

Eg. Microsoft LifeChat LX-3000 has

numid=6,iface=MIXER,name='Speaker Playback Volume'
  ; type=INTEGER,access=rw---R--,values=2,min=0,max=151,step=0
  : values=150,150
  | dBminmax-min=-28.37dB,max=-0.06dB

and the dB range seems to be OK. Web search for "The decibel volume
range for element" also gives other hits with seemingly OK looking
ranges.

Don't disable dB volume unless both the max is negative and the range is
suspiciously small. This should still disable it for the device this
check was originally added for.

Link: https://gitlab.freedesktop.org/pulseaudio/pulseaudio/-/merge_requests/447
Link: 10ac01a206
2025-10-15 21:37:06 +03:00
..
examples spa: examples: local-libcamera: pass camera id to the plugin 2025-08-01 15:40:28 +00:00
include buffer: update comment, we have flags now 2025-10-06 10:31:52 +02:00
include-private/spa-private spa: move dbus helpers out of bluez plugin 2024-02-05 13:03:20 +00:00
lib pod: rework the parser 2025-07-29 15:15:02 +02:00
plugins alsa: acp: don't disable dB if negative max unless range is small 2025-10-15 21:37:06 +03:00
tests tests: fix warning 2025-10-09 09:29:32 +02:00
tools meson.build: make spa-json-dump available for subprojects 2025-07-23 12:19:21 +00:00
meson.build meson: Always use -fno-strict-aliasing and -fno-strict-overflow 2025-07-24 07:30:28 +00:00