]> git.sesse.net Git - ffmpeg/blobdiff - libavcodec/targa.c
fix compilation with --disable-everything --enable-decoder=mpeg2video
[ffmpeg] / libavcodec / targa.c
index 633a6961c186639d4428aa22604f303d9d1ad5ab..b6fe5dfed593ec3b37e2bd587434db2856fb971d 100644 (file)
@@ -189,7 +189,6 @@ static int decode_frame(AVCodecContext *avctx,
                 *pal++ = (b << 16) | (g << 8) | r;
             }
             p->palette_has_changed = 1;
-            avctx->palctrl->palette_changed = 0;
         }
     }
     if((compr & (~TGA_RLE)) == TGA_NODATA)
@@ -199,7 +198,7 @@ static int decode_frame(AVCodecContext *avctx,
             targa_decode_rle(avctx, s, buf, dst, avctx->width, avctx->height, stride, bpp);
         else{
             for(y = 0; y < s->height; y++){
-#ifdef WORDS_BIGENDIAN
+#if HAVE_BIGENDIAN
                 if((s->bpp + 1) >> 3 == 2){
                     uint16_t *dst16 = (uint16_t*)dst;
                     for(x = 0; x < s->width; x++)
@@ -251,7 +250,7 @@ AVCodec targa_decoder = {
     NULL,
     targa_end,
     decode_frame,
-    0,
+    CODEC_CAP_DR1,
     NULL,
     .long_name = NULL_IF_CONFIG_SMALL("Truevision Targa image"),
 };