[FFmpeg-devel] [PATCH]Make xan palette opaque.

Carl Eugen Hoyos cehoyos at ag.or.at
Sat Dec 24 03:27:41 CET 2011


Hi!

Attached patch fixes the palette in wc3 mve files.

Please comment, Carl Eugen
-------------- next part --------------
diff --git a/libavcodec/xan.c b/libavcodec/xan.c
index 8518250..bf4b210 100644
--- a/libavcodec/xan.c
+++ b/libavcodec/xan.c
@@ -535,7 +535,7 @@ static int xan_decode_frame(AVCodecContext *avctx,
                     int g = gamma_lookup[*buf++];
                     int b = gamma_lookup[*buf++];
 #endif
-                    *tmpptr++ = (r << 16) | (g << 8) | b;
+                    *tmpptr++ = (0xFF << 24) | (r << 16) | (g << 8) | b;
                 }
                 s->palettes_count++;
                 break;


More information about the ffmpeg-devel mailing list