demosthenes.info

A blog by Dudley Storey on , , , , , , and anything else that strikes his fancy.

featured articles

popular favourites

HTML5 Audio & Video: Codec Support & Production Workflow

No feature has been more anticipated than finally achieving built-in browser support for audio and video, largely eliminating the need for plugins.  Support for both the <video> and <audio> tags is strong in all modern browsers: what has been contentious has been the decisions regarding codecs

To shorten a very long story, browser programmers choose to support different codecs due to various issues, including licensing, philosophy, and marketshare.  As of this writing and for the foreseeable future, there is no one codec that is shared as a standard by all browsers, which means that we have to encode our audio and video at least twice to achieve complete coverage, at least for now.

The current state of affairs could be summarized as:

HTML5 A/V codec support in browsers (as of February 4, 2011)
ClientWAVEMP3WebM (VP8)Ogg Vorbis / TheoraH264AAC
Firefox 3.5+
Chrome 9+
Safari 3+
Opera 10+
IE 9
iPhone / iPad
Android
Flash

WAV , MP3, and AAC are audio-only; all other formats have both an audio and video component. Microsoft recently announced that it will only support WebM in IE via third-party plugins, but was introducing support for H264 for Firefox and Chrome running on Windows via plugins of its own.

So for maximum coverage our modern web audio and video production workflow would look something like this:

For audio:

encode original, full quality audio as MP3 and Ogg. Most browsers and clients will accept MP3; all others will take the Ogg format.

For video:

encode the video as H264, which is accepted by Safari, IE9, Flash, and all mobile devices. Encode a VP8 version for all other browsers, with a backup of OGV for earlier versions of Firefox without VP* support.

web developer guide

featured comment

by JoelB in Goodbye, JQuery Validation: HTML5 Form Errors With CSS3

what i'm reading

A Storm of Swords: A Song of Ice and Fire: Book Three
A Storm of Swords: A Song of Ice and Fire: Book Three

what i'm watching

Californication: The Third Season
Californication: The Third Season

what i'm playing

Mass Effect 3 Collector's Edition
Mass Effect 3 Collector's Edition

what i'm hearing

Dub FX
Dub FX

blogs

podcasts

no ads ever

This blog is free of advertising, and always will be.

creative commons licensed

The content of this blog is free to use in whatever way you wish under the Creative Commons license.