Hacker Newsnew | past | comments | ask | show | jobs | submitlogin
Mozilla: Stick to Your Ideals, Shun H264 (osnews.com)
50 points by skorks on March 20, 2010 | hide | past | favorite | 54 comments


I've grown increasingly annoyed with Thom over the last two years. The man is an ego-maniac.

The problem is that there's no standard codec for HTML5. The main contestants are H264 and Theora, and so far, it seems like on the browser side of things, Theora is winning out; with a Theora video you can cover Firefox, Chrome, and Opera users - whereas with H264 you miss out on Firefox and Opera users. Since Firefox is by far the largest HTML5 browser, encoding your video in H264 alone is shooting yourself in the foot.

Theora isn't in any position remotely favourable. And definitely not "winning out".

It helps that H264-specific chips are available on just about any mobile device, whereas Theora (or other possible patent-free contestants, like Dirac) does not have this luxury.

Dedicated mobile hardware is a necessity, not a luxury, not until li-ion batteries are superseded by a new breed of whatever with 10 times the charge.


Thom's arguments tend to be based on his personal biases (this company good, that company bad; open source good, closed source bad; etc.) and as a result he sometimes says the stupidest shit to defend them. The thing you quoted about Theora winning out is a perfect example of this, especially the last sentence:

Since Firefox is by far the largest HTML5 browser, encoding your video in H264 alone is shooting yourself in the foot.

Saying so completely disregards the fact that a lot of, maybe even the majority of, the video on the web now is already in h.264 alone, because that's one of the encodings that the Flash plugin supports. And when we add to that the fact that for the foreseeable future there will continue being a non-insignificant portion of people using browsers that do not implement HTML5 at all, meaning video sites which go HTML5 will still have to provide a some form of a fallback - most logically through a Flash player - a fallback that can easily be served to Firefox and Opera users, exactly the opposite of Thom's statement becomes obvious. Not encoding your video in h.264 alone is shooting yourself in the foot - you'd be more than doubling your storage cost and your video transcoding cost and even increasing your bandwidth bill, for no good reason whatsoever.


That kind of fallback provision is exactly what the video element was intended to eliminate.


The <video> tag includes the ability to add multiple <source>s, for fallback. In the tag itself.


I've always found the mobile hardware argument a bit strange. I've never watched any full-length movies on my smartphone, the screen is simply too small to be comfortable. I might watch short Youtube videos once in a while but does it really drain the battery significantly if 3 minutes of video is not hardware accelerated? I find that hard to believe, especially considering that Wifi and 3G already drain tons of battery.

I'd rather watch full-length movies on my laptop, which has a programmable GPU meaning that it's possible for someone to make a hardware accelerated Theora decoder.


They can write software to give you "hardware" accelerated Theora decoders on your phone too, as long as the phone maker lets them. Apple doesn't.

Nokia (who are actively campaigning against Theora) do, so voila:

http://www.schleef.org/blog/2009/11/11/theora-on-ti-c64x-dsp...


Well in countries like South Korea and Japan, they watch live TV, TV shows or movies on their cellphone all the time, so there are plenty of people who would benefit from having hardware acceleration in their mobile devices.


Consider expanding your definition of a mobile device. I watch stuff daily on my iTouch, and I suspect lots of people will use a tablet device for the same.


How much web video do you watch on your phone?

If you're going to pay $10 for a full-length movie, then the H.264 licensing cost is worth it to not have to recharge your phone on the flight. But if you are watching kitteh videos on Youtube, the freedom from cost is worth the tiny additional power draw. Are you really going to watch cat videos for 5 hours?


No, but I'd also prefer my five minute cat video to not eat ten percent of my iPhone's battery. To me, the extra freedom is not worth the extra battery, even if it only quadruples my usage while watching video.

Anyway, it's a moot point. H.264 has "won" in the sense that if HTML5 video happens, most of it will probably be available in that format. The battle was, in my opinion, basically decided when YouTube led with H.264 in their HTML5 experiment. What Mozilla does at this point is relevant only to people who might want to both watch HTML5 video and use Firefox (i.e. they may not be able to do both depending on Mozilla's choice, and on whether a dual-content model is feasible and desirable for most web developers -- hint: probably not).

This is not that big of a deal. There are at least two other no-cost browsers on the important operating systems that will support HTML5 video, three on Windows.


Quite simply (IMO):

Youtube + iPhone = win for h.264.

Hardware decoders are an extra bonus, and h.264 is definitely superior quality-wise to theora. Given all that, Firefox without h.264 is likely to lose significant ground to Chrome for that reason alone.


If you've got an iPhone? Probably a fair amount.

But consider that the battery argument holds for every battery-powered device. Laptops, the iPad / iPhone, and even (to get nitpicky) your electrical bill. It likely also will extend to future gaming handhelds, likely to have a hardware decoder (and why not use h.264? high quality and small size) and run on batteries. The market that is effected is (if not now, likely to be soon) in the hundreds of millions of people, with many many hours each.

I'll be incredibly conservative, and say "a billion hours". Might that be worth reducing power use?


H.264 is not more power efficient than Theora.

It compresses better so that it's got higher quality per bit, but it achieves that by using more computing power on both the encode and decode end. Consider gzip vs bzip for a very rough analogy, more "cleverness" means smaller files but also more computation time. Or think of the CABAC feature that makes your H.264 file 10% smaller but unable to play on iPhones or other low power devices (http://en.wikipedia.org/wiki/CABAC).

H.264 does have "hardware" assisted decode on iPhones but that's a choice made by Apple not a universal law. Despite the constant repetition of the "fact" that H.264 decode is done in custom silicon, it's simply not true. The same DSP or generic video decode units are used for other codecs (inc VC-1, MPEG-2, MPEG-4 part 2, RealVideo). There's no reason Theora can't be accelerated in the same way and it already has been for the OMAP3 chips (as used in N900s, Palm Pre and the Droid).

Here's a link to a company selling software that decodes High Profile H.264 (amongst many other codecs) on OMAP3 SoCs. How would that be remotely possible if H.264 implementations were entirely custom silicon, unchangeable and non-upgradeable?:

http://www.ittiam.com/pages/news/pres-rel-20100215-omap3-720...


Who said that H.264 encoding is entirely custom silicon? And why can't there be custom silicon if other less "hardware" (why do you keep putting it in quotes?) acceleration strategies exist?

You've been pushing this hardware angle hard, and the point is well taken. Yes, you can accelerate Theora if you write some new software. Not every mobile producer has the luxury of letting a third party do that (or putting the resources to do it themselves). But yes, it is possible.

So now all we're left with is that Theora is an inferior codec: worse quality, worse encoding options, more investment required to make it power efficient on mobile.

The industry has decided—with or without Mozilla—long before this question was ever asked. When Youtube started converting everything to H.264, the biggest player moved over. Now you see other smaller players moving to H.264 as well.

All MozillaCo's refusal is doing is ensuring that Flash continues to exist as a video solution for Firefox, playing H.264 and not giving HTML5 video support. The decision has already been made by the big sites!


First post in this thread: "Dedicated mobile hardware is a necessity".

The post I replied to, by a different poster, had taken this one step further and decided that Theora's lack of "a hardware decoder" was going to melt the ice caps.

Who knows exactly what these people meant by "hardware" or "dedicated mobile hardware" but the generally accepted meaning isn't something that can be created by writing software. Writing software for already deployed hardware is considered one of the strengths of Free and Open Source software developers. Creating fabs to build silicon chips with 3 year lead times and magically placing them in devices that have already been sold isn't, and I have repeatedly seen this factoid cited as the reason why Theora is hopeless, regardless of all other considerations.

Here's a quote from the latest Daring Fireball piece:

"There are no hardware decoding chips for Ogg Theora. If you want to send video to mobile devices, H.264 is the only practical encoding for the near future."

If this point is now made and widely accepted and the discussion has moved on to "Theora is an inferior codec: worse quality, worse encoding options etc." then that's great. Inferior is pejorative, and I find "worse quality" to be highly misleading, as if every Theora video will look like something on Youtube, but I'd happily admit to "lower quality per bit" (in fact I do in the post you replied to) which is okay because it has other advantages and room to grow.


going to melt the ice caps.

An exaggeration built on an exaggeration is doomed to fall over. I implied nothing of the sort, and my main goal was just to point out that a hardware decoder is a big deal in terms of battery life, though I admit it didn't come through clearly. Though I will claim that hardware decoding is typically more power efficient than software, and has much more room to improve.

I'm glad to see Theora getting hardware acceleration, especially as I hadn't heard about it, though I'd be curious to see if it'll work on more computers / devices than h.264 is likely to appear on.

As to MPEG-2 and other formats where there are more prevalent hardware decoders, do some comparative runs. h.264 does significantly better per bit from my subjective experiments. It's more future-capable because of that and it's ability to do ridiculously high quality encoding, which combined with a business to hold accountable for problems will likely mean other businesses will choose it over Theora.


> Inferior is pejorative,

Also: accurate.

> and I find "worse quality" to be highly misleading, as if every Theora video will look like something on Youtube,

Also: strictly true that it in apples-to-apples comparisons, H.264 will win in nearly every case. And not by insignificant margins the way audio formats might.

> but I'd happily admit to "lower quality per bit" (in fact I do in the post you replied to) which is okay because it has other advantages and room to grow.

Both are mature video codecs, not kids going to college to find themselves. Unless you are a codec implementor or enthusiast, why do you give a shit how much “room to grow” that your codec has?

Like I said before: All MozillaCo is doing is lying to themselves and ensuring that Firefox uses continue to watch video on Flash—an even more toxic presence on the web. The industry has already moved past them and their reluctance; they're having their argument years too late.


Why not just move back into caves? That would save even more energy.


This is harsh and misleading:

"Opera's refusal to license H264 hasn't got anything to do with ideals, obviously (Opera being proprietary and all), but the Norwegian browser makers believes the license is simply too expensive."

a) it's possible to be idealistic about royalty-free standards without also being idealistic about open source (personally I think both are somewhat pragmatic choices too but whatever), and more importantly:

b) Opera was actually the ones who proposed the idea of the video tag and the use of Theora 3 years ago:

http://my.opera.com/haavard/blog/2007/03/05/1


Mozilla: Stick to your ideals but don't fall on your sword. The openness argument is worth making right now before HTML5 video takes off. It probably won't radically slow the adoption of HTML5 video, or change H264 being the preferred codec, but they might have a chance to make Theora and equal player. They just need to flip WebKit and Microsoft would probably follow. Not totally impossible. Worth the fight in my opinion. What Mozilla needs to be careful of is taking it too far and weakening their market share reducing diversity of browsers if HTML5 video really delivers a better experience than Flash video (and it probably will) This would only serve to strengthen Apple, Google and Microsoft's role in controlling the browser. Mozilla needs to know when they're beat and live to fight another day. I give it another 12-18 months or whenever IE9 hits Windows Update.


It seems to me that the author purposely avoided to discuss the reasons against Mozilla not adopting H264:

- Firefox may be the most used browser on computers, but on mobile devices H264 is clearly winning. And that's where companies want to go right now.

- A lot (the majority?) of online videos are already encoded using H264.

- Flash is also proprietary. So, if you shun H264 for your ideals, you should do so also with flash.


Flash is provided to Mozilla as a third party plugin, so Mozilla doesn't actually have to deal with the licensing fees. If they use H264 for the video element, Mozilla has to license it for their own software.


Why not allow third parties to perform playing <video> tag?


Mozilla won't allow any kind of plugins for <video> because they want to force you to use Theora. You're getting freedom, and you're going to like it. (Because who doesn't want freedom?) The cost of the H.264 license is not the issue.


Now you're just making assumptions. As far as I know, there isn't a single browser that uses plugins for displaying elements defined as part of the HTML specification. With <video> as part of the HTML5 spec, any browser supporting HTML5 is supposed to render <video> tags without relying on 3rd party support. This is the entire reason for <video> existing in the first place.


I don't think this is an assumption: http://weblogs.mozillazine.org/roc/archives/2010/01/video_fr... http://weblogs.mozillazine.org/roc/archives/2009/06/directsh...

I always thought it was a mistake that <img> wasn't extensible (e.g. Mozilla would display PNG with <img> but for IE you'd need <embed> or <object>) and I think that mistake is being perpetuated with <video>.


I'm pretty tired of all the Mozilla bashing and all the H.264 praising. I'd say: give the people their damn H.264, let them face the consequences 10 years later and then tell them "I told you so".


Presumably similar consequences to the ones we suffered for using GIF and JPEG images, and MP3s? Those were tough, I must admit.


Well still today getting a mp3 decoder on some linux platforms, while not tough, is annoying. And still today a better format exists (ogg vorbis) that almost nobody uses, mainly for inertia reasons. So i'd argue that choosing the right format from the start would be nice this time.


Are you insinuating that Ogg Theora is a better format than h.264?


no because it is not, and that's our problem in this situation.

I really hope google is gonna open on2 VP8 : http://www.on2.com/index.php?599

It looks even better than h.264, and it could definately solve this mess


JPEG was specifically created to a be royalty-free standard. JPEG 2000 is the more advanced format with patent royalties that no-one uses on the web for that very reason.


No it wasn't. There was arithmetic encoding option, which was owned and patented by IBM and was not royalty-free. As result everyone implementing codecs had to stick with less efficient, but free Huffman encoding.


Interesting, so that amends my statement to:

Baseline profile JPEG was specifically created to be a royalty-free standard. JPEG-arithmetic is the more advanced optional extension to the format with patent royalties that no-one uses on the web for that very reason.

(Though to be fair to IBM, though the situation appears vaguer than I'd like, it seems they were happy to licence their patents royalty-free, but other companies that also held patents weren't: http://en.wikipedia.org/wiki/Arithmetic_coding#US_patents_on...)


Afaict jpeg, despite it's intentions, has still been dogged by a number of expensive patent fights.


hmm. I think you might be thinking of PNG, which to my memory was the codec developed as a response to patent issues.


There's a flip side to this issue that adds a layer of complexity.

Right now video content owners are encoding video (at a fairly significant cost) to (generally) H264 for streaming media. This includes a wide variety of platforms - not just the web, mobile, internet connected TVs and the new over the top boxes like Roku all support H264 so it has already become a defacto standard for encoding.

Having to re-encode an existing media library to something else like Theora would be a significant cost to content providers with large library archives of content.


Why does anybody need to recode anything? Youtube didn't had to recode all its H263 video to H264 when they switched. You can have both at the same time and only encode newer things in new codecs.

I don't understand why most of the tech community thinks that it's a black-and-white situation. I don't believe that any video site will have the guts to force everything to be H.264 HTML5 video - did you forget that 70% of the visitors, those using IE, cannot watch HTML5 video regardless of the codec? No, if they support HTML5 they'll ensure that they have a Flash fallback and things will work fine on Firefox and Opera even if H.264 is the codec.


Yeah that's the point. HTML5 + h264 by default, Flash + h264 for legacy browsers (like Firefox).


You're right that they need Flash fallback anyway for <IE9, <Safari4, and <Chrome3 — but you're ignoring that it's not a big deal to just do it for Firefox and Opera too. They already have "Works better in Chrome" banners on Youtube for windows users.

Nobody is going to lossily transcode to Theora — they'll just use Flash like they have to already.


H.264 predominance in web video will probably not affect Windows, Mac or Linux users but it will certainly affect BSD and alternative OS users.

I can't see flash content now because my OS of preference doesn't have the plugin. I've been doing fine with out YouTube videos and flash sites. I think I will also be fine with a bigger library of content I can see under Theora and more standard compliant sites even if I can't see H.264 content. But I think Firefox should use the available multimedia frameworks in the different OSes and leave video decoding to the users system.


Even if Mozilla sticks to their guns it doesn't prevent someone from writing a plugin that uses the H264 codecs shipping in Windows & Mac, or x264 on Linux. Sure, it won't be "officially" supported, just like flash doesn't ship with Firefox, but everyone has it.

H264 is baked into silicon, there it's already been decided. Holding out for Theora is like holding out for ogg. Yeah, Wikipedia might use it, but no one else will.


Actually, the video implementation in Firefox makes it extremely difficult to add support for other codecs. Word has it this is specifically so you can't easily add H264 support. So yeah.


"Word has it"? This is an open source project, you can find the reasoning on the bug tracker and the mailing list. I would like to call 'bullshit'.


Why can't firefox just use the already licensed codec for H264 present on the majority of OSs if it's present? Then they'll have support for Therora and H264 on OS X and Windows, and Theora support on Linux.

Costs them nothing and is a win for most of their users.

Am I missing something obvious? I hope they're using DirectShow and Quicktime already anyway for the hardware acceleration.


And why can't other browsers integrate an Ogg codec? It would cost them nothing. The img tag supports several formats, so why should browser developers decide which video codec web companies should use? Especially if their choice is one that costs millions per year. Mozilla is right to promote the free option for us all. They should add Matroska/Dirac/Vorbis in the future, just like they support both JPEG and PNG.


why is codec support even a browser issue? the system is supposed to manage my codecs, and the browser is supposed to use system APIs to play any and all videos i have a codec for.

i'm guessing this is because linux doesn't have a single video codec API, but everything has to explicitly link against codec libraries...


Desktop distributions do have single video codec API (gstreamer).

But browsers are unlikely to use OS-provided libraries for anything downloaded over net, if they can avoid it. If there is a exploit found in third-party code, the browsers cannot work around it and they get the blame (remember the Firefox-on-Windows shell exploit?).


The whole point is to have a video element that any browser that implements html 5 can play, regardless of the system codecs.


I predict this to be just about as successful as the attempts to get everyone to switch over to ogg vorbis as a sound file format.


This quote by Sidney Morgenbesser seems apt. About pragmatism:

"It's all very well in theory but it doesn't work in practice."


What a stupid, contradictive, misleading and deceitful reply from Mozilla (surprised? they are after all interested in stuffing their pockets). And, yeah, I _will_ stick to my ideals: good video; H.264. Please stay out of HTML5, Theora.

add.: I really misread both source and addressee on this one. Seems I cannot manage both breakfast and news digest at the same time. I'll still stick with H.264, though... and breakfast.


This is quite stupid, contradictive, misleading and deceitful but it's not written by Mozilla, it's by a blogger on an obscure news and community site. Therefore the people being asked to stick to their ideals is Mozilla, not you.


Umm, FireFox is already losing market share. After I switched to chrome (and everyone I know have, including my 60 year father, sister, co-workers, etc, anyone who I can show it too, the speed is a killer feature).

How irrelevant would they like to become?




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: