Limit the amount of data scanned when looking for PTSes in duration queries as a
failsafe for kinda broken, potentially large files with sparse or no PTSes.
A previous patch to add streams early to fix playback of
low bitrate streams causes frequent deadlock of a nature
I'm at loss how to fix.
I'm not certain whether it's a bug in decodebin2, or in
that mpegtsdemux patch.
Since it causes a major regression, let it be disabled for now.
This code is to sync to a live source when there is a delay
between start and when we receive the first buffer, so it does
not make sense in a non live case.
This fixes playback of streams where the input timestamps are
based off some arbitrary offset.
https://bugzilla.gnome.org/show_bug.cgi?id=663756
One of my dvds jump on some position and miss about 1 minute of stream.
The reason was mpeg timestamps. On some position scr difference is negative.
It produced negative timestamps. Since it was converted to unsigned value,
gstreamer timestamps was invalid. Instead of increasing mpeg ts,
they was decreasing till it started to be positive.
The jump in timestamps caused mpeg2dec to skip frames to make QoS happy.
This patch just make diff unsigned to avoid negative values.
Signed-off-by: Alexey Fisher <bug-track@fisher-privat.net>
https://bugzilla.gnome.org/show_bug.cgi?id=656115
Some streams declare PIDs but will not send data for them.
Ensure we time out on those, and both send new segments to
keep their time synchronized with the rest, and do not wait
forever before deciding to signal no-more-pads.
https://bugzilla.gnome.org/show_bug.cgi?id=659924
We track streams for which a data callback is set (and for which
pads will be added only when data is received), and signal
no-more-pads when the last pad is added.
https://bugzilla.gnome.org/show_bug.cgi?id=659924
There was a second threshold, which apparently needs to be smaller
than the first, though I'm not certain of it as I don't understand
yet this nest of wtf that is the mpeg demuxer timing logic.
Fixes video freezing on one (corrupted) MPEG sample. It would
previously never think it was out of the discontinuity, and would
push buffers with no timestamp.
Now this took me more than a day's poking at the thing, for just
one constant change, and I'm scared to have to touch this again :S
https://bugzilla.gnome.org/show_bug.cgi?id=655804
In a test stream, I get one buffer with a PTS of about 15 seconds
in the future compared to the previous one, and next buffers with
timestamps continuing where the original ones left off.
This caused the sink to wait 15 seconds to display the frame while
more frames queued up, and then dump all the subsequent frames as
they "arrived too late".
Maybe that threshold should be made configurable, but for now,
make it more smaller to catch more of these.
https://bugzilla.gnome.org/show_bug.cgi?id=655804
Non AV streams keep using the larger threshold (10 minutes), as
subtitles may arrive only every so often.
This is probably the cause for an occasional crash while streaming
MPEG. Blind fix after staring at the code and following logic, so
may or may not fix the issue, I cannot test.
Since the seeking byte offset is chosen by linear interpolation
from SCR values, we need to take that first SCR into account
to end up near the correct offset. Otherwise, as the code does
a linear search after that first seek, it will take a LOOOOOONG
time to get there for streams which don't start at zero.
https://bugzilla.gnome.org/show_bug.cgi?id=659485