mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2025-03-01 10:11:01 +00:00
diracdec: fix full range videos
Full range video had been broken by the introduction of the < 2U check at the following line. The bitstream format kind of implies that the full and limited ranges use different pix_fmts but that's incorrect since we have the avctx->color_range flag. So adjust the pixel range index to be mapped to the same pix_fmts as limited range index. Signed-off-by: Rostislav Pehlivanov <atomnuker@gmail.com>
This commit is contained in:
parent
8a5d4a51ff
commit
ce855bf43b
@ -262,6 +262,9 @@ static int parse_source_parameters(AVDiracSeqHeader *dsh, GetBitContext *gb,
|
|||||||
|
|
||||||
dsh->bit_depth = luma_depth;
|
dsh->bit_depth = luma_depth;
|
||||||
|
|
||||||
|
/* Full range 8 bts uses the same pix_fmts as limited range 8 bits */
|
||||||
|
dsh->pixel_range_index += dsh->pixel_range_index == 1;
|
||||||
|
|
||||||
if (dsh->pixel_range_index < 2U)
|
if (dsh->pixel_range_index < 2U)
|
||||||
return AVERROR_INVALIDDATA;
|
return AVERROR_INVALIDDATA;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user