[FFmpeg-user] Is there a way to cut a video at an exact time ?

bbb ffmpeg-user at bugblatterbeast.de
Sat Apr 13 14:47:59 EEST 2024


I want to cut off the start of a video. When I tell ffmpeg to start at 
an exact time, it refuses to do so and instead starts at a time that's 
somehow "convenient" for ffmpeg. I can only assume that it's probably 
depending on something like a keyframe or an important frame for the 
compression algorithm but I don't really know.

the command:
ffmpeg -ss 0:32.08 -i video.mkv -codec copy -map 0 video.cut.mkv
makes the output start around 0:31 (even when I change the parameter 
value a bit, the result is exactly the same).

Is there a way to make ffmpeg start at the exact time that I specified?
Does it maybe depend on the codec and would it help if I recode it 
before cutting?

It would be even better if I were able to start at a specific frame 
number but I didn't find a parameter to set that. To set a frame offset 
seems only possible when you're exporting to images.


More information about the ffmpeg-user mailing list