Video on websites and mobile device, is there one cross-platform code / format for all this support?

I need to manage a site that will mainly display videos. This website will have a mobile version with <video>, so that video can also be played on ipod, iphone, ipad and other mobile devices in your browser.

The question that I now have is: what format / codec to choose for video conversion, to ensure the best workflow?

The ideal solution is to find a format that can be played as during a flash, video> so that my client does not export the video to multiple files.

For Flash, I would use a .flv file with the h264 codec. But this format / codec cannot be played from <video>, right?

If not, is there a format / codec combination that can work on both?

If not always, what can I do? Do you have a .flv / h264 file for the web version and a .ogg / webM file for the mobile version?

Thank you in advance for your precious advice!

+7
source share
2 answers

I think this is a pretty good article regarding HTML5 video: http://diveintohtml5.ep.io/video.html

Codecs/container IE Firefox Safari Chrome Opera iPhone Android Theora+Vorbis+Ogg · 3.5+ † 5.0+ 10.5+ · · H.264+AAC+MP4 9.0 · 3.0+ · · 3.0+ 2.0+ WebM 9.0 4.0+ † 6.0+ 10.6+ · 2.3 

In accordance with this article there is no format that works everywhere. What I do, I encode the video in H.264. Thus, it works initially on the iPhone, iPad and in safari, and for everyone else I just read the mpg file with a flash player as a backup. (You can directly link to the mp4 file with flash, you do not need to use the FLV file).

To do this, you can use Modernizr to determine if HTML5 is supported, and if so, which formats the browser supports.

Of course, it would be better to have all tree formats, but it is often difficult to process for the client.

+3
source

Here's what's common in Android, iOS, and WP8, Mac, and Windows:

Container Type - MP4, M4V

Encoding type - video H.264, up to 1.5 Mbps, 640 by 480 pixels, 30 frames per second, Low-Complexity version of the H.264 base profile with AAC-LC audio up to 160 Kbps, 48 ​​kHz, stereo audio

+1
source

All Articles