diff --git a/index.html b/index.html index 7a95879..91fcee6 100644 --- a/index.html +++ b/index.html @@ -101,26 +101,22 @@
ffmpeg -i input_file -c:v libx264 -c:a copy output_file
ffmpeg -i input_file -c:v libx264 -pix_fmt yuv420p -c:a copy output_file
This command takes an input file and transcodes it to H.264 with an .mp4 wrapper, keeping the audio the same codec as the original. The libx264 codec defaults to a “medium” preset for compression quality and a CRF of 23. CRF stands for constant rate factor and determines the quality and file size of the resulting H.264 video. A low CRF means high quality and large file size; a high CRF means the opposite.
In order to use the same basic command to make a higher quality file, you can add some of these presets:
-ffmpeg -i input_file -c:v libx264 -preset veryslow -crf 18 -c:a copy output_file
ffmpeg -i input_file -c:v libx264 -pix_fmt yuv420p -preset veryslow -crf 18 -c:a copy output_file
libx264 will use a chroma subsampling scheme that is the closest match to that of the input. This can result in YUV 4:2:0, 4:2:2, or 4:4:4 chroma subsampling. QuickTime and most other non-FFmpeg based players can’t decode H.264 files that are not 4:2:0. In order to allow the video to play in all players, you can specify 4:2:0 chroma subsampling:
-ffmpeg -i input_file -c:v libx264 -pix_fmt yuv420p -preset veryslow -crf 18 -c:a copy output_file