summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2014-11-27 10:11:55 +0100
committerAlessandro Ghedini <alessandro@ghedini.me>2014-12-01 21:05:45 +0100
commit3051ff9f251bef4703b02ce299982b1c62f09894 (patch)
tree5baf53103a647f430d474e43a5dae246a509bff6
parent9bf66294f8acb2133cb4d426ae5eea9b462d246d (diff)
downloadmpv-3051ff9f251bef4703b02ce299982b1c62f09894.tar.bz2
mpv-3051ff9f251bef4703b02ce299982b1c62f09894.tar.xz
mixer: don't show softvol neutral marker on OSD if not using softvol
Also fix the comment on the softvol field.
-rw-r--r--audio/mixer.c4
1 files 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)