[Bug 719785] hlssink does not always adhere to the segment target duration

GStreamer (GNOME Bugzilla) bugzilla at gnome.org
Mon Jan 2 22:52:31 UTC 2017


https://bugzilla.gnome.org/show_bug.cgi?id=719785

--- Comment #5 from minfrin at sharp.fm ---
After a lot of digging I've managed to narrow this down.

The trigger is that for reasons I do not yet understand, none of the buffers
coming through the pipeline are keyframes.

This in turn triggers this code in mpegtsmux.c:

  if (flags & GST_BUFFER_FLAG_DELTA_UNIT) {
    GST_INFO ("pending force key unit, waiting for keyframe");
    goto out;
  }

Because no buffers are keyframes, the forced keyframe event is delayed forever,
and therefore never reaches hlssink, which never rolls over to the next file.

This raises a question - should mpegtsmux be checking for keyframes at all?
Obviously we expect a keyframe here, but instead of a straightforward to
diagnose bug we get broken hlssink behaviour instead, which is counterintuitive
and makes the actual bug very hard to find.

I suspect the problem occurs when a file touches one of the following elements
containing check_pending_key_unit_event():

pi at towerofpi9:~/packages/gstreamer-master/gst-plugins-bad$ grep -r
check_pending_key_unit_event * | grep -v matches
gst/videoparsers/gsth265parse.c:check_pending_key_unit_event (GstEvent *
pending_event, GstSegment * segment,
gst/videoparsers/gsth265parse.c:  if ((event = check_pending_key_unit_event
(h265parse->force_key_unit_event,
gst/videoparsers/gstmpeg4videoparse.c:check_pending_key_unit_event (GstEvent *
pending_event, GstSegment * segment,
gst/videoparsers/gstmpeg4videoparse.c:  if ((event =
check_pending_key_unit_event (mp4vparse->force_key_unit_event,
gst/videoparsers/gsth264parse.c:check_pending_key_unit_event (GstEvent *
pending_event,
gst/videoparsers/gsth264parse.c:  if ((event = check_pending_key_unit_event
(h264parse->force_key_unit_event,
gst/mpegtsmux/mpegtsmux.c:check_pending_key_unit_event (GstEvent *
pending_event, GstSegment * segment,
gst/mpegtsmux/mpegtsmux.c:    event = check_pending_key_unit_event
(mux->downstream_force_key_unit_event,

-- 
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.


More information about the gstreamer-bugs mailing list