Html5 Video: Ffmpeg-encoded Mp4 Not Playing In Any Browser (plays In Vlc Though)
I am trying to serve HTML5 video in MP4 and WEBM fomats. I cannot get all browsers to work though: Browsers which support WEBM (Chrome desktop, Firefox desktop) play the videos f
Solution 1:
No MP4-playing browsers actually seem to have full support for MP4 - especially problematic for MS and Apple's browsers which are trying to create a royalty-hell / monopoly around the format.
I got it to work by re-encoding with the following FFMPEG parameters:
-pix_fmt yuv420p-preset slow-profile:v baseline
Giving a full command line of:
ffmpeg
<INPUT DEFINITION> # e.g. -i <FILE>
-an # if you won't want audio, otherwise -acodec libaac -b:a 128k
-s hd720
-vcodec libx264
-b:v BITRATE # e.g. 4M
-vcodec libx264
-pix_fmt yuv420p
-preset slow
-profile:v baseline
-movflags faststart
-y <OUTPUT PATH>
The problem was ultimately yet another example of proprietary software vendors not properly supporting their own standards.
Post a Comment for "Html5 Video: Ffmpeg-encoded Mp4 Not Playing In Any Browser (plays In Vlc Though)"