Friday 21 May, 2010

Export for iPad

I've had an iPad for over a month now. And even played movies downloaded from iTunes video podcasts. But, up until my friend Dev Benegal asked me, I didn't bother finding out how to create a movie for iPad playback.

Quicktime Pro has presets for the iPhone and cel phones, even various web formats. But nothing yet for the iPad. On the iPad specs page, specs for the movie playback capability of the iPad are stated as...

H.264 video up to 720p, 30 frames per second
Main Profile level 3.1 with AAC-LC audio up to 160 Kbps, 48kHz, stereo audio

MPEG-4 video, up to 2.5 Mbps, 640 by 480 pixels, 30 frames per second,
Simple Profile with AAC-LC audio up to 160 Kbps, 48kHz, stereo audio

Motion JPEG (M-JPEG) up to 35 Mbps, 1280 by 720 pixels, 30 frames per second, 
audio in ulaw, PCM stereo audio in .avi file format

On the actual page this is one long paragraph. I've spaced it out and simplified it.

So this is a good starting point. Looks like the iPad's processor can play back H.264, mp4, and M-jpeg. Data rates for H.264 aren't given, but it can play mp4 at 2.5 Mbps and M-jpeg at 35 Mbps.

While searching for AppleTV movie specs, I came across a Tech note for Apple Tv export
http://developer.apple.com/mac/library/technotes/tn2007/tn2188.html

Here, there's mention of the iPad. And the magic sentence…
"Note: While QuickTime does not provide an iPad specific export component, the iPad is capable of playing media exported using the Apple TV export component."

AppleTV specs are well documented as
Video - H.264 5 Mbps
Size - 1280x720 max 24fps
Audio - AAC-LC 128 Kbps, 44.1 kHz Stereo

So, if one has Apple Compressor installed one can create a preset, input these values and go for it.
If you don't have Apple Compressor, then you need at least Quicktime Pro.

With Quicktime Pro, the settings would be…




I made a small tweak to the size and set it to 1024x768 with a letterbox added in case the original was not in the 1024x768 proportion. 


If you need the movie to be generic and playable on a MacBook/Pro as well AppleTV, then you can omit the 1024x768 resize and stay with 1280x720. Resizing to 1024x768 will make the frame size about 20% smaller at the same data rate so it might be of a better quality visually.

The export is slow. My test export of 1 min
On a MacBook Pro 2.33 GHz, with 2 Gb RAM
took 14 mins.
Going from H.264 at 1920x1080 at 80 Mbps to H.264 1024x768 at 5 Mbps.
Depending on the format of your original, your mileage may vary.

A tip to make this go faster is to change the encoding settings from multi-pass to single pass in the Video settings window. With that set, the same 1 min movie took under 3 mins. Either way the quality was great.

To get the movie into iPad you need to take it into iTunes and select it for syncing when you connect the iPad to your Mac.


This might work for movies ripped from DVDs as well, though Apple hasn't designed it that way. They expect you to buy the movies from the iTunes store.

No comments:

Post a Comment

Place your comment on what I have written here. If you want to ask a a question or expect a response from me consider mailing me. My address is linked in the margin.

If its advice for a commercial project, I may expect to be compensated for a response.