mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2024-12-23 12:43:46 +02:00
indeo4: reuse context block VLC for band instead of defaulting
Currently if no custom block VLC is specified for band, a default block VLC will be used, while the global block VLC stored in the context should be used instead. This fixes decoding of one sample I have.
This commit is contained in:
parent
6647aa0426
commit
2cf5d29110
@ -362,9 +362,12 @@ static int decode_band_hdr(IVI45DecContext *ctx, IVIBandDesc *band,
|
|||||||
}
|
}
|
||||||
|
|
||||||
/* decode block huffman codebook */
|
/* decode block huffman codebook */
|
||||||
if (ff_ivi_dec_huff_desc(&ctx->gb, get_bits1(&ctx->gb), IVI_BLK_HUFF,
|
if (!get_bits1(&ctx->gb))
|
||||||
&band->blk_vlc, avctx))
|
band->blk_vlc.tab = ctx->blk_vlc.tab;
|
||||||
return AVERROR_INVALIDDATA;
|
else
|
||||||
|
if (ff_ivi_dec_huff_desc(&ctx->gb, 1, IVI_BLK_HUFF,
|
||||||
|
&band->blk_vlc, avctx))
|
||||||
|
return AVERROR_INVALIDDATA;
|
||||||
|
|
||||||
/* select appropriate rvmap table for this band */
|
/* select appropriate rvmap table for this band */
|
||||||
band->rvmap_sel = get_bits1(&ctx->gb) ? get_bits(&ctx->gb, 3) : 8;
|
band->rvmap_sel = get_bits1(&ctx->gb) ? get_bits(&ctx->gb, 3) : 8;
|
||||||
|
Loading…
Reference in New Issue
Block a user