diff options
Diffstat (limited to 'gst-libs/ext/libav/libavcodec/bmp.c')
-rw-r--r-- | gst-libs/ext/libav/libavcodec/bmp.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/gst-libs/ext/libav/libavcodec/bmp.c b/gst-libs/ext/libav/libavcodec/bmp.c index 1f725f5..974db49 100644 --- a/gst-libs/ext/libav/libavcodec/bmp.c +++ b/gst-libs/ext/libav/libavcodec/bmp.c @@ -227,9 +227,6 @@ static int bmp_decode_frame(AVCodecContext *avctx, if(comp == BMP_RLE4 || comp == BMP_RLE8) memset(p->data[0], 0, avctx->height * p->linesize[0]); - if(depth == 4 || depth == 8) - memset(p->data[1], 0, 1024); - if(height > 0){ ptr = p->data[0] + (avctx->height - 1) * p->linesize[0]; linesize = -p->linesize[0]; @@ -240,6 +237,9 @@ static int bmp_decode_frame(AVCodecContext *avctx, if(avctx->pix_fmt == PIX_FMT_PAL8){ int colors = 1 << depth; + + memset(p->data[1], 0, 1024); + if(ihsize >= 36){ int t; buf = buf0 + 46; |