Highly Recommended

FFmpeg is a free command-line tool to decode, encode, convert, and mux media files. With it, you can easily convert between most video and audio formats, create video slideshows out of photos, and much, much more. It is a great tool to master, and can be incorporated as the backend for custom media tools. It is available for Windows, Linux, and Mac.

FFmpeg Website


What It's For

FFmpeg is for precise control over media encoding, or as the backend for other programs. FFmpeg gives you all the tools, formats, and commands you can wish for to convert between any video or audio formats. It can also mux audio and video together from different sources, and even stitch photos together. For those who are comfortable with the command line, this is the best tool out there for encoding media. For those who are not, it's never too late to learn!

FFmpeg Examples

ffmpeg -hwaccel cuvid -c:v hevc_cuvid -resize 1280x720 -i input.mov -c:v hevc_nvenc -cq 21 -c:a copy output.mov

Use hardware acceleration to downsize an HEVC video file to 720p at a lower bitrate. Useful for generating proxies at lightning speed. Requires a compatible NVIDIA graphics card.

ffmpeg -i testfile.mp4 -i reference.mp4 -lavfi psnr -f null -

Calculates the PSNR between two videos. Used to determine the similarity; for example to determine the exact amount of loss a lossy conversion introduces.

ffmpeg -i video.mp4 -i audio.wav -c:v copy -c:a aac -b:a 320k -af "pan=stereo|c0=c0|c1=c1" -shortest -map 0:v:0 -map 1:a:0 output.mp4

Muxes video and audio together, while selecting only the first two channels from the audio file and converting audio to AAC format. In this example, the video stream is copied and thus introduces no loss, while the audio is converted to 320kbps AAC.