Praising h.264 once more

I am amazed with Apple’s implementation of h.264. If you go right now at Apple’s front page you will see a random “Mac vs PC” TV commercial. The one I stumbled on is 30 seconds, 12 FPS, 1.01 MBs filesize, 642×362 size (high-resolution), AAC stereo sound and 16 millions of colors. This means that each second of playback uses about 34 KBs of data, and each frame is at around 2.8 KBs. This is amazing. Now, sure, MPEG4 does not encode parts of a frame that haven’t changed, so it saves on filesize. But the quality of each frame is so good, that I am sure that without Photoshop’s enhanced JPEG algorithm I wouldn’t be able to save a JPEG 642×362 frame in less than 40 KBs. And that’s only 1 frame, not 12. And don’t forget that there’s stereo sound packed in the video file too, plus QuickTime’s container overhead…

In my opinion, h.264 has only two problems:
1. Extremely slow encoding times. We are talking in many-many hours of encoding for a single movie with QuickTime. I think it took about 5 hours to encode for the QVGA iPod a 150min movie on my 867 Mhz Powerbook G4. The open source utilities for h.264 encoding (e.g. the ones that come with freeware Handbrake) are even slower.
2. There are weird artifacts when the frames are dark. For example, on a movie scene where it’s night/dark, you will see some excessive 4-color bleeding. I can’t quite describe it well, but here’s a grab shot on a 16 million color screen. The problem is visible on LCD and well-configured CRT screens on many trailers on Apple’s own web site.

It would also be nice if the open source community had a better support for it. While normal-sized h.264 videos work well, 1080p videos don’t. If your video is 1920 pixels wide (HD resolution), for the last 320 pixels on the right you will get a green or pink color and no picture. Yup, you guessed it! They have hard-coded the decoding process for 1600×1200 monitors! The problem exists with all the serious compatibility-wise OSS media players: mplayer, Xine and VLC (they all use the same ffmpeg decoder).

Post a comment »

Hugo wrote on June 21st, 2006 at 1:10 AM PST:

The people at agree with you, anyway the best decoder around seems to coreavc.

Comments are closed as this blog post is now archived.

Lines, paragraphs break automatically. HTML allowed: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>

The URI to TrackBack this blog entry is this. And here is the RSS 2.0 for comments on this post.