Creating Chrome.mp4 compatible with ffmpeg from the command line

How do you encode the .mp4 file from the command line using ffmpeg, so it works in chrome? This can be very difficult, because ffmpeg has many combinations of options, and Chrome is sensitive to color coding of the output format.

+4
source share
1 answer

The solution is to use the "-pix_fmt yuv420p" parameter:

ps>ffmpeg.exe -i $input\$file -y -strict experimental -acodec aac -ac 2 -ab 160k -vcodec libx264 -s 640x480 -pix_fmt yuv420p -preset slow -profile:v baseline -level 30 -maxrate 10000000 -bufsize 10000000 -b 1200k -f mp4 -threads 0 $output\$file.iphone.mp4 

Ffmpeg version N-46936-g8b6aeb1

Hope this helps you get chrome compatible videos.

+5
source

Source: https://habr.com/ru/post/1447743/


All Articles