From 3051ff9f251bef4703b02ce299982b1c62f09894 Mon Sep 17 00:00:00 2001 From: wm4 Date: Thu, 27 Nov 2014 10:11:55 +0100 Subject: [PATCH] mixer: don't show softvol neutral marker on OSD if not using softvol Also fix the comment on the softvol field. --- audio/mixer.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/audio/mixer.c b/audio/mixer.c index e02388851c..ced2196215 100644 --- a/audio/mixer.c +++ b/audio/mixer.c @@ -36,7 +36,7 @@ struct mixer { struct ao *ao; struct af_stream *af; // Static, dependent on ao/softvol settings - bool softvol; // use AO (true) or af_volume (false) + bool softvol; // use AO (false) or af_volume (true) bool ao_softvol; // AO has private or per-app volume bool emulate_mute; // if true, emulate mute with volume=0 // Last known values (possibly out of sync with reality) @@ -72,7 +72,7 @@ bool mixer_audio_initialized(struct mixer *mixer) float mixer_getneutralvolume(struct mixer *mixer) { // gain == 1 - return 1.0 / mixer->opts->softvol_max * 100.0 * 100.0; + return mixer->softvol ? 1.0 / mixer->opts->softvol_max * 100.0 * 100.0 : 100; } static void checkvolume(struct mixer *mixer)