mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-24 10:41:04 +00:00
videodecoder: Don't give out bogus frame deadlines
Make sure the frame deadline was set before calculating the max_decode_time. Fixes problems with ffmpeg skipping frames when it doesn't need to, when the input doesn't have full timestamping (divx in avi)
This commit is contained in:
parent
9a79a145b1
commit
b7759a4d42
1 changed files with 2 additions and 1 deletions
|
@ -2853,7 +2853,8 @@ gst_video_decoder_get_max_decode_time (GstVideoDecoder *
|
|||
|
||||
GST_OBJECT_LOCK (decoder);
|
||||
earliest_time = decoder->priv->earliest_time;
|
||||
if (GST_CLOCK_TIME_IS_VALID (earliest_time))
|
||||
if (GST_CLOCK_TIME_IS_VALID (earliest_time)
|
||||
&& GST_CLOCK_TIME_IS_VALID (frame->deadline))
|
||||
deadline = GST_CLOCK_DIFF (earliest_time, frame->deadline);
|
||||
else
|
||||
deadline = G_MAXINT64;
|
||||
|
|
Loading…
Reference in a new issue