[FFmpeg-cvslog] Print an error if -r and -vsync 0 are used together.

Carl Eugen Hoyos git at videolan.org
Thu Oct 23 23:46:25 CEST 2014


ffmpeg | branch: master | Carl Eugen Hoyos <cehoyos at ag.or.at> | Thu Oct 23 23:27:46 2014 +0200| [7a649e07830cf9aa83881b5c80bd4223b77ba523] | committer: Carl Eugen Hoyos

Print an error if -r and -vsync 0 are used together.

Fixes ticket #4041.

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

 ffmpeg_opt.c |    2 ++
 1 file changed, 2 insertions(+)

diff --git a/ffmpeg_opt.c b/ffmpeg_opt.c
index 13152d0..7a5eaa5 100644
--- a/ffmpeg_opt.c
+++ b/ffmpeg_opt.c
@@ -1277,6 +1277,8 @@ static OutputStream *new_video_stream(OptionsContext *o, AVFormatContext *oc, in
         av_log(NULL, AV_LOG_FATAL, "Invalid framerate value: %s\n", frame_rate);
         exit_program(1);
     }
+    if (frame_rate && video_sync_method == VSYNC_PASSTHROUGH)
+        av_log(NULL, AV_LOG_ERROR, "Using -vsync 0 and -r can produce invalid output files\n");
 
     MATCH_PER_STREAM_OPT(frame_aspect_ratios, str, frame_aspect_ratio, oc, st);
     if (frame_aspect_ratio) {



More information about the ffmpeg-cvslog mailing list