[FFmpeg-user] Smooth FPS change via ffmpeg

Michael Koch astroelectronic at t-online.de
Tue Sep 24 21:59:16 EEST 2019


Am 23.09.2019 um 14:45 schrieb RazrFalcon:
> Hi!
>
> I have a 240FPS video made by GoPro and I'm looking for a way to gradually
> change a video framerate. If I want to simply slow down a video I can use:
>
> ffmpeg -i raw.mp4 -filter_complex "[v:0]setpts=8*PTS" -r 30 out.mp4
>
> and it works fine. But when I'm trying to use a "variable" framerate like
> this:
>
> ffmpeg -i raw.mp4 -filter_complex "[v:0]setpts='lerp(2,8,T/5)*PTS'" -r 30
> out.mp4
>
> (5 is a video duration in seconds)
>
> the resulting video stutters a lot.
>
> Is there are a correct way to smoothly change the framerate using some
> curve/function?

Have a look at this posting where a totally different approach is described:
http://ffmpeg.org/pipermail/ffmpeg-user/2017-June/036310.html

Michael



More information about the ffmpeg-user mailing list