h265parse->sei_pos = -1;
h265parse->keyframe = FALSE;
h265parse->header = FALSE;
+ h265parse->have_vps_in_frame = FALSE;
+ h265parse->have_sps_in_frame = FALSE;
+ h265parse->have_pps_in_frame = FALSE;
gst_adapter_clear (h265parse->frame_out);
}
GST_DEBUG_OBJECT (h265parse, "triggering src caps check");
h265parse->update_caps = TRUE;
h265parse->have_vps = TRUE;
+ h265parse->have_vps_in_frame = TRUE;
if (h265parse->push_codec && h265parse->have_pps) {
/* VPS/SPS/PPS found in stream before the first pre_push_frame, no need
* to forcibly push at start */
GST_DEBUG_OBJECT (h265parse, "triggering src caps check");
h265parse->update_caps = TRUE;
h265parse->have_sps = TRUE;
+ h265parse->have_sps_in_frame = TRUE;
if (h265parse->push_codec && h265parse->have_pps) {
/* SPS and PPS found in stream before the first pre_push_frame, no need
* to forcibly push at start */
h265parse->update_caps = TRUE;
}
h265parse->have_pps = TRUE;
+ h265parse->have_pps_in_frame = TRUE;
if (h265parse->push_codec && h265parse->have_sps) {
/* SPS and PPS found in stream before the first pre_push_frame, no need
* to forcibly push at start */
gboolean send_done = FALSE;
GstClockTime timestamp = GST_BUFFER_TIMESTAMP (buffer);
+ if (h265parse->have_vps_in_frame && h265parse->have_sps_in_frame
+ && h265parse->have_pps_in_frame) {
+ GST_DEBUG_OBJECT (h265parse, "VPS/SPS/PPS exist in frame, will not insert");
+ return TRUE;
+ }
+
if (h265parse->align == GST_H265_PARSE_ALIGN_NAL) {
/* send separate config NAL buffers */
GST_DEBUG_OBJECT (h265parse, "- sending VPS/SPS/PPS");