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:
The h.264 file looks like this: download [9]
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:
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.
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
Anhang | Größe |
---|---|
bbb-400bps.ogg [7] | 212.88 KB |
bbb-400bps.264 [9] | 214.39 KB |
encode.sh [11] | 428 Bytes |
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.draketo.de/files/bbb-400bps.ogg
[8] http://www.mozilla-europe.org/en/firefox/
[9] http://www.draketo.de/files/bbb-400bps_0.264
[10] http://identi.ca/notice/25557640
[11] http://www.draketo.de/files/encode_0.sh