[FFmpeg-cvslog] Increase Bitmap Brothers JV palette dynamics.

Carl Eugen Hoyos git at videolan.org
Sat Nov 12 20:57:04 CET 2011


ffmpeg | branch: master | Carl Eugen Hoyos <cehoyos at ag.or.at> | Sat Nov 12 20:56:07 2011 +0100| [3230c756f8891a35f4eb2b298a74185fe4816741] | committer: Carl Eugen Hoyos

Increase Bitmap Brothers JV palette dynamics.

Approved-by: Peter Ross

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=3230c756f8891a35f4eb2b298a74185fe4816741
---

 libavcodec/jvdec.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/libavcodec/jvdec.c b/libavcodec/jvdec.c
index faf4a10..7ceba1e 100644
--- a/libavcodec/jvdec.c
+++ b/libavcodec/jvdec.c
@@ -172,7 +172,8 @@ static int decode_frame(AVCodecContext *avctx,
 
     if (buf < buf_end) {
         for (i = 0; i < AVPALETTE_COUNT && buf + 3 <= buf_end; i++) {
-            s->palette[i] = (0xFF << 24) | AV_RB24(buf) << 2;
+            uint32_t pal = AV_RB24(buf);
+            s->palette[i] = 0xFF << 24 | pal << 2 | pal >> 4 & 0x30303;
             buf += 3;
         }
         s->palette_has_changed = 1;



More information about the ffmpeg-cvslog mailing list