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:
authorMichael Niedermayer <michael@niedermayer.cc>2016-08-17 00:04:00 +0300
committerMichael Niedermayer <michael@niedermayer.cc>2016-08-17 00:04:00 +0300
commitb1d12509384b9285b85f5c183772d75a81e74009 (patch)
tree924ac856a8048aae63d2ecb135444cacd2358337 /libavcodec/ffv1enc_template.c
parent87da1188981fbfa802d1ccfe22bf32cc76f52ada (diff)
avcodec/ffv1: Fix rgb plane ordering in experimental planar RGB
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Diffstat (limited to 'libavcodec/ffv1enc_template.c')
-rw-r--r--libavcodec/ffv1enc_template.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/libavcodec/ffv1enc_template.c b/libavcodec/ffv1enc_template.c
index f6c44a36a0..01aee4935b 100644
--- a/libavcodec/ffv1enc_template.c
+++ b/libavcodec/ffv1enc_template.c
@@ -150,6 +150,10 @@ static int RENAME(encode_rgb_frame)(FFV1Context *s, const uint8_t *src[3],
g = (v >> 8) & 0xFF;
r = (v >> 16) & 0xFF;
a = v >> 24;
+ } else if (sizeof(TYPE) == 4) {
+ g = *((const uint16_t *)(src[0] + x*2 + stride[0]*y));
+ b = *((const uint16_t *)(src[1] + x*2 + stride[1]*y));
+ r = *((const uint16_t *)(src[2] + x*2 + stride[2]*y));
} else {
b = *((const uint16_t *)(src[0] + x*2 + stride[0]*y));
g = *((const uint16_t *)(src[1] + x*2 + stride[1]*y));