mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-20 08:41:07 +00:00
mpegvideoparse: Apply previous timestamp when there isn't any newer.
If the current incoming packet didn't carry a timestamp, but a previous packet had one we didn't yet use, then apply that timestamp to the next picture. Fixes: #618336
This commit is contained in:
parent
85d3c03d26
commit
2f9b765326
1 changed files with 2 additions and 1 deletions
|
@ -319,7 +319,8 @@ handle_packet (MPEGPacketiser * p, guint64 offset, guint8 pack_type)
|
|||
* previous buffer in order to handle this correctly. It would still be
|
||||
* possible to get it wrong if there was a PES packet smaller than 3 bytes
|
||||
* but anyone that does that can suck it. */
|
||||
if (offset >= p->tracked_offset) {
|
||||
if ((offset >= p->tracked_offset)
|
||||
&& (p->cur_buf_ts != GST_CLOCK_TIME_NONE)) {
|
||||
/* sync word started within this buffer - take the cur ts */
|
||||
ts = p->cur_buf_ts;
|
||||
p->cur_buf_ts = GST_CLOCK_TIME_NONE;
|
||||
|
|
Loading…
Reference in a new issue