Skip to main content

HTML5 Audio/Video formats

So what is HTML5? What are the specs for audio and video?

Here is a good introduction http://www.w3schools.com/html/html5_intro.asp
and for html5 audio http://www.w3schools.com/html/html5_audio.asp

We can add an <audio> tag to our html

<audio controls="controls">
  <source src="/horse.ogg" type="audio/ogg">
  <source src="/horse.mp3" type="audio/mpeg">
Your browser does not support the audio element.
</audio>

Instead of "Your browser does not support the audio element." we will use javascript to run the player and provide a flash fallback if the browser does not support our media.

MyMuse uses JPlayer http://www.jplayer.org. They have a list on browser support for various file types:
http://www.jplayer.org/latest/developer-guide/#reference-html5-media

Also, read about essential formats:
http://www.jplayer.org/latest/developer-guide/#jPlayer-essential-formats

and media encoding:
http://www.jplayer.org/latest/developer-guide/#jPlayer-media-encoding

  • Hits: 18675