multiqueue: Fix interleave calculation for data before segment start
authorEdward Hervey <edward@centricular.com>
Wed, 2 Mar 2022 16:07:37 +0000 (17:07 +0100)
committerGStreamer Marge Bot <gitlab-merge-bot@gstreamer-foundation.org>
Wed, 9 Mar 2022 18:49:51 +0000 (18:49 +0000)
commit2943d92389e46addafdd81c07ba35f48c8187a48
tree82da7b02a210e98776163852c7fec7bb4df91d58
parentb141324eae5e2360a25ea7a208b45a78ecfef75e
multiqueue: Fix interleave calculation for data before segment start

This commit modifies the interleave calculation to allow growing when incoming
data is before the segment start.

The rationale is that there is no requirement whatsoever for data before the
segment start to be "coherent" on all streams.

For example, a demuxer could rightfully send data from the video stream from the
previous keyframe (potentially quite a bit before the segment start) and the
audio from just before the segment start.

This will activate the same logic as growing the interleave when some streams
haven't received buffers yet.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/1892>
subprojects/gstreamer/plugins/elements/gstmultiqueue.c