aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Niedermayer <michael@niedermayer.cc>2023-12-24 19:54:27 +0100
committerMichael Niedermayer <michael@niedermayer.cc>2023-12-29 01:19:03 +0100
commitaec67d3d7d2895bfea61aa1358d9d8e956f8615c (patch)
tree209c7dbbab540d466f1272bb0ffebe3b33f91788
parentd909d8e5e0fbce42ecb10ee6e73def1f1e42ece4 (diff)
downloadffmpeg-aec67d3d7d2895bfea61aa1358d9d8e956f8615c.tar.gz
avfilter/af_stereowiden: Round length to nearest
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
-rw-r--r--libavfilter/af_stereowiden.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavfilter/af_stereowiden.c b/libavfilter/af_stereowiden.c
index af4b23e8a5..97610a4f30 100644
--- a/libavfilter/af_stereowiden.c
+++ b/libavfilter/af_stereowiden.c
@@ -72,7 +72,7 @@ static int config_input(AVFilterLink *inlink)
AVFilterContext *ctx = inlink->dst;
StereoWidenContext *s = ctx->priv;
- s->length = s->delay * inlink->sample_rate / 1000;
+ s->length = lrintf(s->delay * inlink->sample_rate / 1000);
s->length *= 2;
s->buffer = av_calloc(s->length, sizeof(*s->buffer));
if (!s->buffer)