Chapter 7. The Horribly Complex World of Web Video
Use only that which works, and take it from any place you can find it.
— Bruce Lee (as quoted in Bruce Lee:Fighting Spirit by Bruce Thomas)
One of the most important early drivers for adoption of HTML5 was Apple’s decision against supporting Adobe Flash on iOS devices. Picking the most important side effect of that decision would be difficult, but one of the biggest was certainly the mad scramble to produce web video that could play on the iPhone. This, of course, meant the HTML5 video
element was suddenly important. It was so important, for a time at least, that it was common for people to say simply “HTML5” when they were really discussing serving video with the video
element.
The thing is, from the first, the video
element has been a tricky thing to work with in any practical way. This is strange because at first glance it looks pretty easy to understand, and at its most basic, using the video
element is straightforward. If you’re familiar with the way the replaced elements like img
or object
(handy for embedding Flash!) work, you will understand how to use video
(and audio
for that matter.) The associated video
API is also simple with easy-to-understand play
and pause
methods.
If only the full story were that simple.
Video is the best current example of a web technology that, because of one factor or another, fails to live up to its promise. Because of that failure, it’s much easier to move away from a pure standards-based approach ...
Get The Uncertain Web now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.