I have a video file say input.mp4 and I would like to loop this file say 6 times The following command does the job

ffmpeg -stream_loop 5 -i input.mp4  -c copy out.mp4

However, the result is a shaky video. It plays the input.mp4 first time without any problem and then it adds a few milliseconds before playing it the second time. And the third time and so on. The second iteration onwards, the video looks shaky and not as clear as the first time.

Am I using the command/option wrong ? Any hints would be appreciated.

I looked at this question but it did not help

  • Which ffmpeg version?
    – Gyan
    Nov 8, 2022 at 8:06
  • It is version 5.1.2
    – Trojosh
    Nov 9, 2022 at 20:34


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.