summaryrefslogtreecommitdiffstats
path: root/audio
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2012-11-24 21:40:48 +0100
committerwm4 <wm4@nowhere>2012-11-24 21:40:48 +0100
commit99e178f1e8e2a6b9d7b3dd937f5214827f192c08 (patch)
tree32fca1a6907eb56c4181dc29e4ed4334fa9996bf /audio
parent4c21ad1f55c31596c32eb006b4d91fe0d036f466 (diff)
downloadmpv-99e178f1e8e2a6b9d7b3dd937f5214827f192c08.tar.bz2
mpv-99e178f1e8e2a6b9d7b3dd937f5214827f192c08.tar.xz
ao_pulse: do not allow setting volume over 100%
PulseAudio allows applications to set volume over 100%. To make this possible, the PulseAudio daemon raises the global system volume, and tries to lower other applications volumes. Unfortunately, this doesn't work out and doesn't manage to keep the effective volume level of these other applications. To make it short: this functionality invoked PulseAudio bugs. Disable it. This essentially reverts commit 85a64b.
Diffstat (limited to 'audio')
-rw-r--r--audio/out/ao_pulse.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/audio/out/ao_pulse.c b/audio/out/ao_pulse.c
index 539dbfa640..7e561c9541 100644
--- a/audio/out/ao_pulse.c
+++ b/audio/out/ao_pulse.c
@@ -34,8 +34,8 @@
#define PULSE_CLIENT_NAME "mpv"
-#define VOL_PA2MP(v) ((v) * 100 / PA_VOLUME_UI_MAX)
-#define VOL_MP2PA(v) ((v) * PA_VOLUME_UI_MAX / 100)
+#define VOL_PA2MP(v) ((v) * 100 / PA_VOLUME_NORM)
+#define VOL_MP2PA(v) ((v) * PA_VOLUME_NORM / 100)
struct priv {
// PulseAudio playback stream object