diff --git a/NEWS b/NEWS index 951914d2e..b203e1d0b 100644 --- a/NEWS +++ b/NEWS @@ -1,6 +1,7 @@ ver 0.20.3 (not yet released) * protocol - "playlistadd" creates new playlist if it does not exist, as documented +* replay gain: don't reset ReplayGain levels when unpausing playback * silence surround channels when converting from stereo * use shortcuts such as "dsd64" in log messages diff --git a/src/output/Source.cxx b/src/output/Source.cxx index fbaa9ff80..e5a67f1bd 100644 --- a/src/output/Source.cxx +++ b/src/output/Source.cxx @@ -95,13 +95,17 @@ try { assert(audio_format.IsValid()); /* the replay_gain filter cannot fail here */ - if (prepared_replay_gain_filter != nullptr) + if (prepared_replay_gain_filter != nullptr) { + replay_gain_serial = 0; replay_gain_filter_instance = prepared_replay_gain_filter->Open(audio_format); + } - if (prepared_other_replay_gain_filter != nullptr) + if (prepared_other_replay_gain_filter != nullptr) { + other_replay_gain_serial = 0; other_replay_gain_filter_instance = prepared_other_replay_gain_filter->Open(audio_format); + } filter_instance = prepared_filter->Open(audio_format); } catch (...) { diff --git a/src/output/Source.hxx b/src/output/Source.hxx index e15c2c3fb..c9bbd45f6 100644 --- a/src/output/Source.hxx +++ b/src/output/Source.hxx @@ -64,13 +64,13 @@ class AudioOutputSource { * The serial number of the last replay gain info. 0 means no * replay gain info was available. */ - unsigned replay_gain_serial = 0; + unsigned replay_gain_serial; /** * The serial number of the last replay gain info by the * "other" chunk during cross-fading. */ - unsigned other_replay_gain_serial = 0; + unsigned other_replay_gain_serial; /** * The replay_gain_filter_plugin instance of this audio