[gst-cvs] gst-ffmpeg: ffdec: be more careful with DTS timestamp interpolation
Wim Taymans
wtay at kemper.freedesktop.org
Fri Oct 22 04:06:42 PDT 2010
Module: gst-ffmpeg
Branch: master
Commit: cc2a6e493bdc93cb23e71a5d519087aa4a648357
URL: http://cgit.freedesktop.org/gstreamer/gst-ffmpeg/commit/?id=cc2a6e493bdc93cb23e71a5d519087aa4a648357
Author: Wim Taymans <wim.taymans at collabora.co.uk>
Date: Fri Oct 22 12:59:02 2010 +0200
ffdec: be more careful with DTS timestamp interpolation
Don't use -1 and 0 duration buffers to calculate next output timestamp as they
are very likely wrong.
Fixes #632877
---
ext/ffmpeg/gstffmpegdec.c | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/ext/ffmpeg/gstffmpegdec.c b/ext/ffmpeg/gstffmpegdec.c
index db1364c..b959598 100644
--- a/ext/ffmpeg/gstffmpegdec.c
+++ b/ext/ffmpeg/gstffmpegdec.c
@@ -1903,8 +1903,10 @@ gst_ffmpegdec_video_frame (GstFFMpegDec * ffmpegdec,
}
GST_BUFFER_DURATION (*outbuf) = out_duration;
- if (out_timestamp != -1 && out_duration != -1)
+ if (out_timestamp != -1 && out_duration != -1 && out_duration != 0)
ffmpegdec->next_out = out_timestamp + out_duration;
+ else
+ ffmpegdec->next_out = -1;
/* palette is not part of raw video frame in gst and the size
* of the outgoing buffer needs to be adjusted accordingly */
More information about the Gstreamer-commits
mailing list