Zwillingssterns Weltenwald
Published on Zwillingssterns Weltenwald (http://www.zwillingsstern.de)

Startseite > Ogg Theora and h.264 - which video codec as standard for internet-video?

Ogg Theora and h.264 - which video codec as standard for internet-video?

Links:
- Video encoder comparison [1] - a much more thorough comparision than mine

We had a kinda long discussion [2] on identi.ca [3] about Ogg Theora [4] and h.264, and since we lacked a simple comparision method, I hacked up a quick script to test them.

It uses frames from Big Buck Bunny [5] and outputs the files bbb.ogg and bbb.264 (license: cc by [6]).

The ogg file looks like this:

download [7] - if your browser supported the html5 video via theora (like Firefox [8]), then you could watch it directly here.

The h.264 file looks like this: download [9]

Results

What you can see by comparing both is that h.264 wins in terms of raw image quality at the same bitrate (single pass).

So why am I still strongly in favor of Ogg Theora?

The reason is simple:

Due to licensing costs of h.264 (a few millions per year, due from 2015 onwards) making h.264 the standard for internet video would have the effect that only big companies would be able to make a video enabled browser - or we would get a kind of video tax for free software: if you want to view internet video with free software, you have to pay for the right to use the x264 library (else the developers couldn't cough up the money to pay for the parent license). And noone but the main developers and huge corporations could distribute the x264 library, because they’d have to pay license fees for that.

And noone could hack on the browser or library and distribute the changed version, so the whole idea of free software would be led ad absurdum. It wouldn't matter that all code would be free licensed, since only those with a h.264 patent license could change it.

So this post boils down to a simple message:

“Support !theora against h.264 and #flash [as video codec for the web]. Otherwise only big companies will be able to write video browsers - or we get a h.264 tax on !fs” [10]

Theoras raw quality may still be worse, but the license costs and their implications provide very clear reasons for supporting Theora - which in my view are far more important than raw technical stuff.

The test-script

for k in {0..1}
     do for i in {0..9}
         do for j in {0..9}
             do
wget http://media.xiph.org/BBB/BBB-360-png/big_buck_bunny_00$k$i$j.png
         done
     done
done

mplayer -vo yuv4mpeg -ao null -nosound mf://*png -mf fps=50

theora_encoder_example -z 0 --soft-target -V 400 -o bbb.ogg stream.yuv

mencoder stream.yuv -ovc x264 -of rawvideo -o bbb.264 -x264encopts bitrate=400 -aspect 16:9 -nosound -vf scale=640:360,harddup

AnhangGröße
bbb-400bps.ogg [7]212.88 KB
bbb-400bps.264 [9]214.39 KB
encode.sh [11]428 Bytes
Werke von Arne Babenhauserheide. Lizensiert, wo nichts anderes steht, unter der GPLv3 or later und weiteren freien Lizenzen.

Diese Seite nutzt Cookies. Und Bilder. Manchmal auch Text. Eins davon muss ich wohl erwähnen — sagen die meisten anderen, und ich habe grade keine Zeit, Rechtstexte dazu zu lesen…


Source URL: http://www.zwillingsstern.de/light/english/ogg-theora-and-h264

Links:
[1] http://keyj.s2000.ws/?p=356
[2] http://identi.ca/conversation/25438506
[3] http://identi.ca
[4] http://theora.org
[5] http://bigbuckbunny.org
[6] http://www.bigbuckbunny.org/index.php/about/
[7] http://www.zwillingsstern.de/files/bbb-400bps.ogg
[8] http://www.mozilla-europe.org/en/firefox/
[9] http://www.zwillingsstern.de/files/bbb-400bps_0.264
[10] http://identi.ca/notice/25557640
[11] http://www.zwillingsstern.de/files/encode_0.sh