Commit 33756c53 authored by Niklas Haas's avatar Niklas Haas Committed by James Almer

avcodec/h264_sei: fix H.274 film grain parsing

The current code reads the wrong number of bits for `fg_model_id`, which
causes all of the values downstream of this to contain corrupt values.

Fixes: corrupt SEI values
Fixes: 4ff73addSigned-off-by: 's avatarNiklas Haas <git@haasn.dev>
parent 83860a3d
......@@ -424,7 +424,7 @@ static int decode_film_grain_characteristics(H264SEIFilmGrainCharacteristics *h,
if (h->present) {
memset(h, 0, sizeof(*h));
h->model_id = get_bits(gb, 8);
h->model_id = get_bits(gb, 2);
h->separate_colour_description_present_flag = get_bits1(gb);
if (h->separate_colour_description_present_flag) {
h->bit_depth_luma = get_bits(gb, 3) + 8;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment