mirror of
https://github.com/librempeg/librempeg
synced 2024-11-23 11:39:47 +00:00
avfilter/af_dynaudnorm: fix possible clipping at start when alt-boundary mode is disabled
This commit is contained in:
parent
3fe49b51fc
commit
fcbaeefb45
@ -471,7 +471,7 @@ static void update_gain_history(DynamicAudioNormalizerContext *s, int channel,
|
||||
{
|
||||
if (cqueue_empty(s->gain_history_original[channel])) {
|
||||
const int pre_fill_size = s->filter_size / 2;
|
||||
const double initial_value = s->alt_boundary_mode ? gain.max_gain : s->peak_value;
|
||||
const double initial_value = s->alt_boundary_mode ? gain.max_gain : FFMIN(1.0, gain.max_gain);
|
||||
|
||||
s->prev_amplification_factor[channel] = initial_value;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user