[FFmpeg-trac] #694(undetermined:new): Speed-up/Slow-down a video

FFmpeg trac at avcodec.org
Mon Nov 28 20:35:42 CET 2011


#694: Speed-up/Slow-down a video
-------------------------------------+-------------------------------------
             Reporter:  burek        |                     Type:
               Status:  new          |  enhancement
            Component:               |                 Priority:  wish
  undetermined                       |                  Version:
             Keywords:               |  unspecified
             Blocking:               |               Blocked By:
Analyzed by developer:  0            |  Reproduced by developer:  0
-------------------------------------+-------------------------------------
 The problem: Video is recorded at 10 fps, but always plays at 30 fps
 (erroneously encoded somehow). How to correct such a video to play with
 the correct speed?

 I'm not sure if there is an easy way to do this, but afaik there is no
 simple way to do this, because FFmpeg does not do any kind of buffering of
 frames it reads from the input, it just drops/duplicates the frames.

 We had few people on irc channel, trying to fix their videos, using
 FFmpeg, that's why I'm posting this. We resolved this issue by writting
 raw video to a tmp file (to loose the timestamps) and then we read the tmp
 file with a slower frame rate, like this:

 > ffmpeg -i input.264 -f rawvideo -r 30 tmpfile
 > ffmpeg -s 1280x720 -r 10 -f rawvideo -i tmpfile output.mp4

 The video in input.264 would play nice at 10 fps, but somehow timestamps
 are saved just like it's 30 fps video, so it was always played back too
 fast.

 The suggestion is to create an enhancement to rearrange timestamps on the
 fly, to avoid the need for the tmp file, to be able to speed up/slow down
 a video stream (also if possible even without re-encoding it).

-- 
Ticket URL: <https://ffmpeg.org/trac/ffmpeg/ticket/694>
FFmpeg <http://ffmpeg.org>
FFmpeg issue tracker


More information about the FFmpeg-trac mailing list