Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/FFmpeg/FFmpeg.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndreas Rheinhardt <andreas.rheinhardt@outlook.com>2022-11-06 19:15:22 +0300
committerAndreas Rheinhardt <andreas.rheinhardt@outlook.com>2022-11-09 19:39:00 +0300
commitcf57147da1e8d93d51288dc40ae1bcd11bbc4a0b (patch)
tree65c6b4d06c7a7886b164335eb962d079848ca88e
parente72e8ec515faffb4819ea355b47e6bee382a0456 (diff)
avfilter/phase_template: Fix left-shift of negative numbers
Affected the filter-phase FATE-test. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
-rw-r--r--libavfilter/phase_template.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavfilter/phase_template.c b/libavfilter/phase_template.c
index 491612b826..8450670234 100644
--- a/libavfilter/phase_template.c
+++ b/libavfilter/phase_template.c
@@ -46,7 +46,7 @@
*
* (The result is actually multiplied by 25)
*/
-#define DIFF(a, as, b, bs) ((t) = ((*(a) - (b)[bs]) << 2) + (a)[(as) << 1] - (b)[-(bs)], (t) * (t))
+#define DIFF(a, as, b, bs) ((t) = ((*(a) - (b)[bs]) * 4) + (a)[(as) * 2] - (b)[-(bs)], (t) * (t))
/*
* Find which field combination has the smallest average squared difference