[FFmpeg-cvslog] avconv: use only meaningful timestamps in start time check.

Anton Khirnov git at videolan.org
Sat Jul 7 03:02:43 CEST 2012


ffmpeg | branch: master | Anton Khirnov <anton at khirnov.net> | Wed Jul  4 02:56:38 2012 +0200| [53ddd43f0c9aa9d1060d70a7e921e1ae74601947] | committer: Anton Khirnov

avconv: use only meaningful timestamps in start time check.

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=53ddd43f0c9aa9d1060d70a7e921e1ae74601947
---

 avconv.c |    9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

diff --git a/avconv.c b/avconv.c
index c59916e..fad0626 100644
--- a/avconv.c
+++ b/avconv.c
@@ -1560,7 +1560,7 @@ static int poll_filters(void)
                 break;
 
             avfilter_copy_buf_props(filtered_frame, picref);
-            if (picref->pts != AV_NOPTS_VALUE)
+            if (picref->pts != AV_NOPTS_VALUE) {
                 filtered_frame->pts = av_rescale_q(picref->pts,
                                                    ost->filter->filter->inputs[0]->time_base,
                                                    ost->st->codec->time_base) -
@@ -1568,9 +1568,10 @@ static int poll_filters(void)
                                                    AV_TIME_BASE_Q,
                                                    ost->st->codec->time_base);
 
-            if (of->start_time && filtered_frame->pts < 0) {
-                avfilter_unref_buffer(picref);
-                continue;
+                if (of->start_time && filtered_frame->pts < 0) {
+                    avfilter_unref_buffer(picref);
+                    continue;
+                }
             }
 
             switch (ost->filter->filter->inputs[0]->type) {



More information about the ffmpeg-cvslog mailing list