diff --git a/gst/rtp/gstrtph265pay.c b/gst/rtp/gstrtph265pay.c index ed1d8b9b09..b63360e664 100644 --- a/gst/rtp/gstrtph265pay.c +++ b/gst/rtp/gstrtph265pay.c @@ -566,7 +566,7 @@ gst_rtp_h265_pay_setcaps (GstRTPBasePayload * basepayload, GstCaps * caps) size -= 23; if (num_arrays > 0) { - if (data[0] == (0x00 | 0x20)) { /* VPS */ + if ((data[0] & 0x3f) == 0x20) { /* VPS */ data++; num_vps = data[0] << 8 | data[1]; @@ -603,7 +603,7 @@ gst_rtp_h265_pay_setcaps (GstRTPBasePayload * basepayload, GstCaps * caps) } if (num_arrays > 0) { - if (data[0] == (0x00 | 0x21)) { /* SPS */ + if ((data[0] & 0x3f) == 0x21) { /* SPS */ data++; num_sps = data[0] << 8 | data[1]; @@ -640,7 +640,7 @@ gst_rtp_h265_pay_setcaps (GstRTPBasePayload * basepayload, GstCaps * caps) } if (num_arrays > 0) { - if (data[0] == (0x00 | 0x22)) { /* PPS */ + if ((data[0] & 0x3f) == 0x22) { /* PPS */ data++; num_pps = data[0] << 8 | data[1]; diff --git a/tests/check/elements/rtp-payloading.c b/tests/check/elements/rtp-payloading.c index 1f864a6f24..96a601ed8f 100644 --- a/tests/check/elements/rtp-payloading.c +++ b/tests/check/elements/rtp-payloading.c @@ -842,8 +842,10 @@ GST_START_TEST (rtp_h265_list_lt_mtu_hvc1) rtp_pipeline_test (rtp_h265_list_lt_mtu_frame_data_hvc1, rtp_h265_list_lt_mtu_frame_data_size, rtp_h265_list_lt_mtu_frame_count, "video/x-h265,stream-format=(string)hvc1,alignment=(string)au," - "codec_data=(buffer)01640032ffe1002a67640032ac1b1a80a03dff016e02020280000" - "003008000000a74300018fff5de5c68600031ffebbcb85001000468ee3830", + "codec_data=(buffer)0101c000000080000000000099f000fcfdf8f800000203a000010" + "01840010c01ffff01c000000300800000030000030099ac0900a10001003042010101c00" + "0000300800000030000030099a00a080f1fe36bbb5377725d602dc040404100000300010" + "00003000a0800a2000100074401c172b02240", "rtph265pay", "rtph265depay", rtp_h265_list_lt_mtu_bytes_sent_hvc1, rtp_h265_list_lt_mtu_mtu_size, TRUE); } @@ -898,8 +900,10 @@ GST_START_TEST (rtp_h265_list_gt_mtu_hvc1) rtp_pipeline_test (rtp_h265_list_gt_mtu_frame_data_hvc1, rtp_h265_list_gt_mtu_frame_data_size, rtp_h265_list_gt_mtu_frame_count, "video/x-h265,stream-format=(string)hvc1,alignment=(string)au," - "codec_data=(buffer)01640032ffe1002a67640032ac1b1a80a03dff016e02020280000" - "003008000000a74300018fff5de5c68600031ffebbcb85001000468ee3830", + "codec_data=(buffer)0101c000000080000000000099f000fcfdf8f800000203a000010" + "01840010c01ffff01c000000300800000030000030099ac0900a10001003042010101c00" + "0000300800000030000030099a00a080f1fe36bbb5377725d602dc040404100000300010" + "00003000a0800a2000100074401c172b02240", "rtph265pay", "rtph265depay", rtp_h265_list_gt_mtu_bytes_sent_hvc1, rtp_h265_list_gt_mtu_mtu_size, TRUE); }