Seek commands and tsdemux element

Mario Montagud Climent mamontor at upv.es
Fri Jul 22 09:02:28 UTC 2016


Hi Tim,

These notes are very useful, and have helped in clarifying some of our  
doubts. Thank you!

The qtdemux behaves as expected when setting the FLAG_KEY_UNIT and  
FLAG_ACCURATE flags. In the latter case, as expected, the segment  
start field is equal to the target seek position. However, it does not  
happen when using tsdemux, as we’ve measured a variable offset between  
2.2 and 2.4 s, much larger than the GoP length (1s, 30fps)!

Moreover, we experienced the following issues when using MPEG2-TS:

We created the master and slave MPEG2-TSs using ffmpeg, and we added  
numeric overlays (PTS and frame numbers) to visually check the sync  
performance. We set a frame rate of 30fps, and we tested with  
different GoP lengths. When using GoP of 30 frames (1s), the result of  
the seek command was OK, but when using other (larger) GoP lengths, we  
had to add an offset (a period around 2 or 3 GoPs) to the target seek  
position to successfully seek to the targeted media stream position  
(the current playou position of the master stream). We had to infer  
that offset from the numeric overlays on the video frames of both  
streams, which is clearly not a good solution. We performed these  
tests in both Ubuntu and Android.

So, we assume that (at this moment) it is not convenient to use  
MPEG2-TS streams for the slave streams we want to synchronize, as the  
behavior and performance of the tsdemux when seeking is (still) not so  
good.

We are not testing with DASH content for the slave streams, and the  
behavior and performance of the seek position is much better.

Thank you very much for your help!

Cheers,

Mario Montagud

Tim Müller <tim at centricular.com> escribió:

> On Tue, 2016-07-19 at 13:24 +0200, Mario Montagud Climent wrote:
>
> Hi Mario,
>
> I've written down some notes on the ideal expected behaviour of
> demuxers here:
> https://cgit.freedesktop.org/gstreamer/gstreamer/tree/docs/design/part-
> seeking.txt#n115
>
> Which might answer some questions.
>
> Typically people either seek with FLAG_KEY_UNIT or FLAG_ACCURATE.
>
> Cheers
>  -Tim
>
> --
>
> Tim Müller, Centricular Ltd - http://www.centricular.com
> _______________________________________________
> gstreamer-devel mailing list
> gstreamer-devel at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel




More information about the gstreamer-devel mailing list