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

GStreamer (GNOME Bugzilla) bugzilla at gnome.org
Wed Jan 4 07:54:50 UTC 2017


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

--- Comment #12 from minfrin at sharp.fm ---
> Why isn't there a keyframe on the stream? Or the problem is that
> the parser isn't recognizing and marking the keyframes as such?

As I said above, the stream in my case is broken, and you'll see that by the
attachment I added. In this particular case, something has gone wrong with the
encoder, and there a no keyframes.

Then this bug kicks in - the hlssink element stops slicing, because all the
force-key-unit events are being delayed indefinitely. The segment currently
being written to now grows without bounds, until the partition runs out of
space, at that point the whole gstreamer pipeline shuts down.

Obviously we want keyframes at the HLS boundaries, but that is impossible to
achieve when other elements in the pipeline keep delaying the force-key-unit
events without being told to do so and moving those boundaries.

This bug also causes mayhem on live streams coming from unreliable sources like
DVB. The stream runs for hours without a problem, then suddenly out of the blue
keyframes stop arriving because of some kind of stream error, and thus bug gets
triggered. Segment grows indefinitely, out of space, pipeline shuts down.

> What exactly is the pipeline that you're using?

The pipeline is a transcoding pipeline, converting h264 back into h264 after
resizing.

It's the equivalent of "[src] ! [timing-element] ! decodebin ! encodebin !
hlssink".

The timing element sends downstream force-key-unit events, which are
intercepted by h264parse, which then delays the force-key-unit, ruining the
timing. Because h264 is being transcoded to h264 in this case, h264parse
appears twice in the pipeline, so it breaks whether the timing is controlled by
the src, or whether controlled by the sink.

-- 
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