summaryrefslogtreecommitdiffstats
path: root/libavfilter/vf_paletteuse.c
diff options
context:
space:
mode:
authorClément Bœsch <u@pkh.me>2017-10-28 18:01:41 +0200
committerClément Bœsch <u@pkh.me>2017-10-28 18:03:28 +0200
commit157d08e971f43dd17ba2c3618e31c76fa938efe2 (patch)
treeb7d967a2115a478343544e8edc0a57a6028a5cf7 /libavfilter/vf_paletteuse.c
parent3d547c19c211ac61771629e6bcdfbdba393a76ae (diff)
downloadffmpeg-streaming-157d08e971f43dd17ba2c3618e31c76fa938efe2.zip
ffmpeg-streaming-157d08e971f43dd17ba2c3618e31c76fa938efe2.tar.gz
lavfi/paletteuse: fix debug_mean_error after aba926e7d
Diffstat (limited to 'libavfilter/vf_paletteuse.c')
-rw-r--r--libavfilter/vf_paletteuse.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/libavfilter/vf_paletteuse.c b/libavfilter/vf_paletteuse.c
index 19017ac..84c31de 100644
--- a/libavfilter/vf_paletteuse.c
+++ b/libavfilter/vf_paletteuse.c
@@ -787,9 +787,9 @@ static void debug_mean_error(PaletteUseContext *s, const AVFrame *in1,
for (x = 0; x < in1->width; x++) {
const uint32_t c1 = src1[x];
const uint32_t c2 = palette[src2[x]];
- const uint8_t rgb1[] = {c1 >> 16 & 0xff, c1 >> 8 & 0xff, c1 & 0xff};
- const uint8_t rgb2[] = {c2 >> 16 & 0xff, c2 >> 8 & 0xff, c2 & 0xff};
- mean_err += diff(rgb1, rgb2, s->trans_thresh);
+ const uint8_t argb1[] = {0xff, c1 >> 16 & 0xff, c1 >> 8 & 0xff, c1 & 0xff};
+ const uint8_t argb2[] = {0xff, c2 >> 16 & 0xff, c2 >> 8 & 0xff, c2 & 0xff};
+ mean_err += diff(argb1, argb2, s->trans_thresh);
}
src1 += src1_linesize;
src2 += src2_linesize;
OpenPOWER on IntegriCloud