[FFmpeg-devel] [PATCH v2 3/5] avfilter/vf_super2xsai: fix big-endian writing
Muhammad Faiz
mfcc64 at gmail.com
Mon Jan 28 12:07:39 EET 2019
Fix mismatched checksum on fate-filter-pixfmts-super2xsai.
Signed-off-by: Muhammad Faiz <mfcc64 at gmail.com>
---
libavfilter/vf_super2xsai.c | 4 ++--
tests/ref/fate/filter-pixfmts-super2xsai | 16 ++++++++--------
2 files changed, 10 insertions(+), 10 deletions(-)
diff --git a/libavfilter/vf_super2xsai.c b/libavfilter/vf_super2xsai.c
index 87eec04da8..4901e03e23 100644
--- a/libavfilter/vf_super2xsai.c
+++ b/libavfilter/vf_super2xsai.c
@@ -180,8 +180,8 @@ static void super2xsai(AVFilterContext *ctx,
break;
default: // bpp = 2
if (s->is_be) {
- AV_WB32(dst_line[0] + x * 4, product1a | (product1b << 16));
- AV_WB32(dst_line[1] + x * 4, product2a | (product2b << 16));
+ AV_WB32(dst_line[0] + x * 4, (product1a << 16) | product1b);
+ AV_WB32(dst_line[1] + x * 4, (product2a << 16) | product2b);
} else {
AV_WL32(dst_line[0] + x * 4, product1a | (product1b << 16));
AV_WL32(dst_line[1] + x * 4, product2a | (product2b << 16));
diff --git a/tests/ref/fate/filter-pixfmts-super2xsai b/tests/ref/fate/filter-pixfmts-super2xsai
index 04cf00dae4..6e9e1144d3 100644
--- a/tests/ref/fate/filter-pixfmts-super2xsai
+++ b/tests/ref/fate/filter-pixfmts-super2xsai
@@ -1,18 +1,18 @@
abgr e21be14b5fe9d7a29740a418c325b17e
argb 563489534663cb2b32beed2b41370c37
bgr24 a933eac9bb53c3ce3c33950b229996b5
-bgr555be d6d14ec3ae9ffffed3006a253e9b9a9a
-bgr555be(le) d69e39a24027afcb28feaabb46f0948d
+bgr555be a293b0b4c6747b5b3f8fd4f9c4907ed1
+bgr555be(le) 70b819425f79f823356229b90b41cc84
bgr555le 70b819425f79f823356229b90b41cc84
-bgr565be 4ffcc26e740622ffd3314fe251e97804
-bgr565be(le) 78f3b43ddcc1f8558444c97d249a6123
+bgr565be aa4a030327932a2c72dff315bf4d7385
+bgr565be(le) 6fb9dc50a81b853800ba65d5ec6b8417
bgr565le 6fb9dc50a81b853800ba65d5ec6b8417
bgra e9cc6644e2f35103c241094ab4bb8fec
rgb24 3fd7653f414f350ddb0c0a236ce0c809
-rgb555be 0f34c006142babd10065d90b8c2ce3d6
-rgb555be(le) f2f9f30e8be582729f12a03331e3c635
+rgb555be 35860f8ca6c7e314dc3f658be6bb44ca
+rgb555be(le) 53325a20c913826566880eb25d1d2946
rgb555le 53325a20c913826566880eb25d1d2946
-rgb565be 9889faf1a636161f3049b78e92db7d89
-rgb565be(le) 340ffed3645809f68346280764ca3de6
+rgb565be 2c5adfea1c3843ca04355b0ccd293783
+rgb565be(le) 14fe550f449a7539d9f1e99e85cf40f1
rgb565le 14fe550f449a7539d9f1e99e85cf40f1
rgba 7041184d35c316e73e849504b64bc4f6
--
2.17.2
More information about the ffmpeg-devel
mailing list