Juan Pablo Fernandez
Juan Pablo Fernandez

Reputation: 2546

Why the following ffmpeg command outpus an eleven minutes long video?

Why the following ffmpeg command outpus an eleven minutes long video?

 ffmpeg -ss 600 -i 01x01TheStrongestMan.mp4 -to 660 -vcodec copy -acodec copy -y outputxxx.mp4

I want to slice the video from the 600 second to the 660 second, the output should be a 1 minute long video. How can I do that and why my command is wrong?

Thanks.

Upvotes: 0

Views: 136

Answers (1)

video.baba
video.baba

Reputation: 884

Here's a few little test examples I did which may shed some light.

Seek before: (Quicker but less accurate)

ffmpeg -ss 600 -to 660 -i movie.mkv -vcodec copy -acodec copy -y output1.mp4

Seek after: (Slower but more accurate)

ffmpeg -i movie.mkv -ss 600 -to 660 -vcodec copy -acodec copy -y output2.mp4

Seek before and after: (Quick and accurate)

ffmpeg -ss 500 -i movie.mkv -ss 100 -to 160 -vcodec copy -acodec copy -y output3.mp4

However........

Depending on which frames are which, you'll not always get accurate cuts/trims. You'll also get different results, or find one method better than another, depending on whether you are just copying streams, or encoding.

Upvotes: 0

Related Questions