Commit 98251f01 authored by Nicolas Dufresne's avatar Nicolas Dufresne Committed by Olivier Crête

rtph264depay: Fix handling or marker on STAP-A

Only forward the marker for the last NAL of the STAP-A. Otherwise each NAL
endup being assumed to be a full frame which may break rendering.

Fixes 557
parent 0725e54d
...@@ -1103,6 +1103,8 @@ gst_rtp_h264_depay_process (GstRTPBaseDepayload * depayload, GstRTPBuffer * rtp) ...@@ -1103,6 +1103,8 @@ gst_rtp_h264_depay_process (GstRTPBaseDepayload * depayload, GstRTPBuffer * rtp)
/* STAP-A Single-time aggregation packet 5.7.1 */ /* STAP-A Single-time aggregation packet 5.7.1 */
while (payload_len > 2) { while (payload_len > 2) {
gboolean last = FALSE;
/* 1 /* 1
* 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 * 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
* +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ * +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
...@@ -1136,8 +1138,11 @@ gst_rtp_h264_depay_process (GstRTPBaseDepayload * depayload, GstRTPBuffer * rtp) ...@@ -1136,8 +1138,11 @@ gst_rtp_h264_depay_process (GstRTPBaseDepayload * depayload, GstRTPBuffer * rtp)
gst_rtp_copy_video_meta (rtph264depay, outbuf, rtp->buffer); gst_rtp_copy_video_meta (rtph264depay, outbuf, rtp->buffer);
if (payload_len - nalu_size <= 2)
last = TRUE;
gst_rtp_h264_depay_handle_nal (rtph264depay, outbuf, timestamp, gst_rtp_h264_depay_handle_nal (rtph264depay, outbuf, timestamp,
marker); marker && last);
payload += nalu_size; payload += nalu_size;
payload_len -= nalu_size; payload_len -= nalu_size;
......
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