From 968a3508e192e6266900d439e85ff0d0f71908ab Mon Sep 17 00:00:00 2001 From: Seungha Yang Date: Wed, 11 Sep 2019 17:59:37 +0900 Subject: [PATCH] h264parser: Expose parsed GstH264PPS::pic_scaling_matrix_present_flag --- gst-libs/gst/codecparsers/gsth264parser.c | 5 ++--- gst-libs/gst/codecparsers/gsth264parser.h | 3 +++ 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/gst-libs/gst/codecparsers/gsth264parser.c b/gst-libs/gst/codecparsers/gsth264parser.c index 3b2a3258f5..4af4d44f96 100644 --- a/gst-libs/gst/codecparsers/gsth264parser.c +++ b/gst-libs/gst/codecparsers/gsth264parser.c @@ -1956,7 +1956,6 @@ gst_h264_parse_pps (GstH264NalParser * nalparser, GstH264NalUnit * nalu, NalReader nr; GstH264SPS *sps; gint sps_id; - guint8 pic_scaling_matrix_present_flag; gint qp_bd_offset; GST_DEBUG ("parsing PPS"); @@ -2036,8 +2035,8 @@ gst_h264_parse_pps (GstH264NalParser * nalparser, GstH264NalUnit * nalu, READ_UINT8 (&nr, pps->transform_8x8_mode_flag, 1); - READ_UINT8 (&nr, pic_scaling_matrix_present_flag, 1); - if (pic_scaling_matrix_present_flag) { + READ_UINT8 (&nr, pps->pic_scaling_matrix_present_flag, 1); + if (pps->pic_scaling_matrix_present_flag) { guint8 n_lists; n_lists = 6 + ((sps->chroma_format_idc != 3) ? 2 : 6) * diff --git a/gst-libs/gst/codecparsers/gsth264parser.h b/gst-libs/gst/codecparsers/gsth264parser.h index 478f755638..dda51d6da9 100644 --- a/gst-libs/gst/codecparsers/gsth264parser.h +++ b/gst-libs/gst/codecparsers/gsth264parser.h @@ -808,6 +808,9 @@ struct _GstH264PPS guint8 second_chroma_qp_index_offset; gboolean valid; + + /* Since: 1.18 */ + guint8 pic_scaling_matrix_present_flag; }; struct _GstH264RefPicListModification