Browse Source

avfilter/af_dynaudnorm: do not error out if even filter size was given

Instead issue a warning and make filter size odd number.
tags/n4.3
Paul B Mahol 6 years ago
parent
commit
7bb09e57e0
1 changed files with 2 additions and 2 deletions
  1. +2
    -2
      libavfilter/af_dynaudnorm.c

+ 2
- 2
libavfilter/af_dynaudnorm.c View File

@@ -110,8 +110,8 @@ static av_cold int init(AVFilterContext *ctx)
DynamicAudioNormalizerContext *s = ctx->priv;

if (!(s->filter_size & 1)) {
av_log(ctx, AV_LOG_ERROR, "filter size %d is invalid. Must be an odd value.\n", s->filter_size);
return AVERROR(EINVAL);
av_log(ctx, AV_LOG_WARNING, "filter size %d is invalid. Changing to an odd value.\n", s->filter_size);
s->filter_size |= 1;
}

return 0;


Loading…
Cancel
Save