Ticket #895: patchsunrast32bpp.diff

File patchsunrast32bpp.diff, 578 bytes (added by cehoyos, 5 years ago)
  • libavcodec/sunrast.c

    diff --git a/libavcodec/sunrast.c b/libavcodec/sunrast.c
    index c33265d..509df73 100644
    a b static int sunrast_decode_frame(AVCodecContext *avctx, void *data, 
    9898        case 24: 
    9999            avctx->pix_fmt = (type == RT_FORMAT_RGB) ? PIX_FMT_RGB24 : PIX_FMT_BGR24; 
    100100            break; 
     101        case 32: 
     102            avctx->pix_fmt = (type == RT_FORMAT_RGB) ? PIX_FMT_RGBA : PIX_FMT_BGRA; 
     103            break; 
    101104        default: 
    102105            av_log(avctx, AV_LOG_ERROR, "invalid depth\n"); 
    103106            return -1;