FFmpeg is a tool that helps you work with audio and visual files. It can significantly improve the speed of quick edits to a video or stream by editing a copy of the original instead of re-encoding your entire video.
For example if you’d like to grab a 5 minute long clip from your
source.mp4 video that starts at the 5 minute mark until the 10 minute mark you’d run something like the following to save the new clip as
Lets break down what these different flags mean:
-i ./source.mp4is used to specify an input source. In this case we’re referring to a video file named
-ss 00:05:00is used to set a start time offset. This will skip the amount of time specified forward in the input source and then begin the edited clip.
-to 00:10:00is used to set an end time for the clip. This will cause the exported clip to only include content up to the provided time in the input source.
-c copyis used to specify a codec. In this case the
copycodec is used to help improve the speed of encoding.
copyis a special value in
FFmpegnot to reencode your video.
Note: You may leave off either
-toparameters to start from the start of the input source or to include all content until the end of the input source.
FFmpeg is available for macOS, Windows and Linux distributions.
You can find out more about using
FFmpeg at the official