Log in

View Full Version : Futureproof online encoding


edwinbradford
25th February 2011, 17:55
Can I check I've understood this correctly. I want to create a future proof pipeline for encoding video to be viewed online in browsers using HTML5 with flash fall back? Up to now I've only encoded H.264 using MeGUI (great tool).

Currently, MediaElement.js (http://mediaelementjs.com/) looks like it might be the best solution for my needs. It seems like they're suggesting encoding any single video into :

01. H.264 (Apple compatible profile).
02. WebM.
03. Ogg.

However Video for everybody (http://camendesign.com/code/video_for_everybody) on which mediaelement.js is partly based says it only needs two files :

01. MP4.
02. Ogg.

...but on their test page (http://camendesign.com/code/video_for_everybody/test.html) they list three(?) formats :Download Video: Closed Format: "MP4"; Open Format: "OGG" / "WebM"If I understand correctly, WebM is based on Ogg, hence the "/" in that quote, and the benefit of a separate Ogg encode is only to offer HTML5 playback to Firefox and Opera in the meantime before they switch to WebM.

In which case if I just encode :

01. H.264 (Apple compatible profile)
02. WebM

I will have HTML5 future-compatible files with a Flash fall back that utilizes the H.264. Current versions of Firefox and Opera can fall back to Flash and future versions will use the WebM encode.

If each video has a SD and HD version that means I need to create four files per video. Better than six you see.

Any mistakes here?

N.B. in case anyone suggests it, yes I've looked at YouTube and Vimeo, both have restrictions that mean they won't work with my content. Besides, doing it myself is a good learning experience.

AnonCrow
25th February 2011, 18:56
If I understand correctly, WebM is based on Ogg No, WebM is based on (or rather it IS) VP8. The fact that Ogg Theora is based on VP3 is inconsequential.
If each video has a SD and HD version that means I need to create four files per video. Better than six you see.

Might even get away with just 2 videos depending on if/when/how SVC (scalable video coding) support is implemented in html5 and the various flash-players.

sneaker_ger
26th February 2011, 01:42
Yes, AnonCrow is correct.

The browser makers don't agree on a single format, with the following being the candidates:
1. WebM: VP8 video, Ogg Vorbis audio in WebM container (based on Matroska)
2. H.264: H.264 video, AAC audio in MP4 container (this format is already supported by the flash player)

"OGG" in this context most probably refers to Ogg Theora Video (based on VP3) and Ogg Vorbis audio in Ogg Container. None of the browser makers propose this format as WebM is seen as superior in all aspects, so I wouldn't provide it.