mirror of
https://github.com/mpv-player/mpv
synced 2025-01-05 03:06:28 +01:00
mixer: fix lowering hw volume while muted
Lowering volume while muted did not work correctly with audio outputs that support native mute setting separate from volume (ao_alsa and ao_pulse), because the AO-level volume was not set while muted but was still being read back. Fix by setting the AO volume in this case.
This commit is contained in:
parent
772afce75e
commit
dbb4a973d5
@ -126,7 +126,7 @@ void mixer_setvolume(mixer_t *mixer, float l, float r)
|
||||
checkvolume(mixer); // to check mute status and AO support for volume
|
||||
mixer->vol_l = av_clip(l, 0, 100);
|
||||
mixer->vol_r = av_clip(r, 0, 100);
|
||||
if (!mixer->ao || mixer->muted)
|
||||
if (!mixer->ao || mixer->muted_using_volume)
|
||||
return;
|
||||
setvolume_internal(mixer, mixer->vol_l, mixer->vol_r);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user