From 25f90c828aa5842be3f3f63cb2f564f49ac934e9 Mon Sep 17 00:00:00 2001 From: He Junyan Date: Fri, 25 Nov 2022 18:38:27 +0800 Subject: [PATCH] h264parser: Fix a typo in pred_weight_table parsing. When setting default values, the reference list number of l1 is wrong. Fix: https://gitlab.freedesktop.org/gstreamer/gstreamer-vaapi/-/issues/336 Part-of: --- .../gst-plugins-bad/gst-libs/gst/codecparsers/gsth264parser.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/subprojects/gst-plugins-bad/gst-libs/gst/codecparsers/gsth264parser.c b/subprojects/gst-plugins-bad/gst-libs/gst/codecparsers/gsth264parser.c index 25427adc0d..349d6d23b3 100644 --- a/subprojects/gst-plugins-bad/gst-libs/gst/codecparsers/gsth264parser.c +++ b/subprojects/gst-plugins-bad/gst-libs/gst/codecparsers/gsth264parser.c @@ -795,7 +795,7 @@ gst_h264_slice_parse_pred_weight_table (GstH264SliceHdr * slice, p->chroma_weight_l0[i][1] = default_chroma_weight; } if (GST_H264_IS_B_SLICE (slice)) { - for (i = 0; i <= slice->num_ref_idx_l0_active_minus1; i++) { + for (i = 0; i <= slice->num_ref_idx_l1_active_minus1; i++) { p->chroma_weight_l1[i][0] = default_chroma_weight; p->chroma_weight_l1[i][1] = default_chroma_weight; }