]> git.sesse.net Git - ffmpeg/commitdiff
gifdec: fix transparent background color
authorDon Moir <donmoir@comcast.net>
Thu, 27 Dec 2012 18:06:49 +0000 (18:06 +0000)
committerPaul B Mahol <onemda@gmail.com>
Thu, 27 Dec 2012 18:10:25 +0000 (18:10 +0000)
Signed-off-by: Paul B Mahol <onemda@gmail.com>
libavcodec/gifdec.c

index 4f44fd4d5376b391dd2c6d0c80990a8f20290144..a0ffe77183e3581c733e793485ff2ee7ea01d959 100644 (file)
@@ -202,7 +202,7 @@ static int gif_read_image(GifState *s)
         s->gce_w = width; s->gce_h = height;
 
         if (s->gce_disposal == GCE_DISPOSAL_BACKGROUND) {
-            if (s->background_color_index == s->transparent_color_index)
+            if (s->background_color_index >= 0)
                 s->stored_bg_color = s->trans_color;
             else
                 s->stored_bg_color = s->bg_color;