Commit 9c52ab6f authored by Michael Niedermayer's avatar Michael Niedermayer

ffmpeg: treat avi as VFR in framerate conversion code

It can be debated if avi is vfr or cfr, it can be either depending
on the definition of vfr and cfr.
This commit ensures that avi is treated correctly independent of
the AVFMT_VARIABLE_FPS value.
Signed-off-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parent ac4447b6
......@@ -819,8 +819,12 @@ static void do_video_out(AVFormatContext *s,
nb_frames = 1;
format_video_sync = video_sync_method;
if (format_video_sync == VSYNC_AUTO)
format_video_sync = (s->oformat->flags & AVFMT_VARIABLE_FPS) ? ((s->oformat->flags & AVFMT_NOTIMESTAMPS) ? VSYNC_PASSTHROUGH : VSYNC_VFR) : VSYNC_CFR;
if (format_video_sync == VSYNC_AUTO) {
if(!strcmp(s->oformat->name, "avi")) {
format_video_sync = VSYNC_VFR;
} else
format_video_sync = (s->oformat->flags & AVFMT_VARIABLE_FPS) ? ((s->oformat->flags & AVFMT_NOTIMESTAMPS) ? VSYNC_PASSTHROUGH : VSYNC_VFR) : VSYNC_CFR;
}
switch (format_video_sync) {
case VSYNC_CFR:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment