summaryrefslogtreecommitdiff
path: root/libavfilter
diff options
context:
space:
mode:
authorMichael Niedermayer <michael@niedermayer.cc>2021-06-05 20:12:08 +0200
committerMichael Niedermayer <michael@niedermayer.cc>2021-10-06 14:41:41 +0200
commit2e4e045e633189485b5b0af7c5a363a241b4cb50 (patch)
treedad0d7808cc0eb29d0f99135d82e2984bab44484 /libavfilter
parent612d8b02027ed320f820ed7ef22e34eb1f0ab7d3 (diff)
downloadffmpeg-2e4e045e633189485b5b0af7c5a363a241b4cb50.tar.gz
avfilter/vf_fftdnoiz: Use lrintf() in export_row8()
Fixes: 1.04064e+10 is outside the range of representable values of type 'int' Fixes: Ticket 8279 Signed-off-by: Michael Niedermayer <michael@niedermayer.cc> (cherry picked from commit 1f21349d20d9bda8eeeddb23263892be0cea12e3) Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Diffstat (limited to 'libavfilter')
-rw-r--r--libavfilter/vf_fftdnoiz.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavfilter/vf_fftdnoiz.c b/libavfilter/vf_fftdnoiz.c
index 856d716be5..eea1887e40 100644
--- a/libavfilter/vf_fftdnoiz.c
+++ b/libavfilter/vf_fftdnoiz.c
@@ -161,7 +161,7 @@ static void export_row8(FFTComplex *src, uint8_t *dst, int rw, float scale, int
int j;
for (j = 0; j < rw; j++)
- dst[j] = av_clip_uint8(src[j].re * scale + 0.5f);
+ dst[j] = av_clip_uint8(lrintf(src[j].re * scale));
}
static void import_row16(FFTComplex *dst, uint8_t *srcp, int rw)