Monday, September 27, 2010

With the Pages application (part of Apple's iWork suite), we can now easily include audio and video in our ePub-based eBooks. These advanced eBooks are viewable only in the iBooks application on an iPad, iPhone or iPod touch but these iOS devices are selling like hotcakes so that's OK for now. The others will catch up eventually.

However, easy as it is to include audio and video in an ePub using Pages, we still have to exercise care in preparing these media files for our eBooks. It's is quite easy to create a video file that won't play back properly or at all and we don't want to inflict that kind of experience on our readers.

Obviously, Flash is out so we are talking about files that are in an MPEG-4 or QuickTime container. But that's not all. We also have to make sure that the CODEC used for the video track is H.264 and the CODEC used for the audio track is AAC. In addition to that, we must take care to keep the data rate, expressed in bits per second, below certain threshold values. Here, for example, are the
technical specifications for the iPad. Read the sections on "Audio playback" and "TV and video" to get the general idea. No need to study or memorize these, just get the flavor and we'll move on.

These specifications are all aimed at accommodating the requirements of the firmware chips in most mobile devices that decompress and display video. Using dedicated and specialized firmware is far more efficient than decompressing video in software. This yields superior performance and a good video experience.

So, with all of these specifications, it should be easy to get things wrong, right? No, that's not the case. There are lots of virtually foolproof ways to make sure that the audio and video you include in an ePub file will play back properly in iBooks on an iOS device, currently the only venue where this kind of media can be played back in an ePub file.

There are two general scenarios that will determine how best to proceed: whether we are creating the media from scratch or repurposing extant media. Let's examine both cases.

Creating and exporting media from scratch. This is easiest scenario but has the most variations. If you are creating video with or without an audio track, always export using the iPhone preset (480x360 ). This will usually keep the data rate below one megabit per second which will perform very well on any iOS device. There are many applications that create video. Similarly, audio-only applications have iPhone presets. Here's a screencast medley of popular MacOS X apps that export video and audio that will be playable in the iBooks app on iOS devices.



Repurposing extant media. There are several good approaches to this task depending upon the characteristics of the source video. The general goal is to convert the source file into a 480x360 H.264/AAC file in an MPEG-4 or QuickTime container. Source files can be almost anything (Flash, DVD, Windows Media, AVI and so on) but you may need to extend your MacOS X system with extra QuickTime components in order to handle all of these. Here is a short list of the most important QuickTime components to add:

Perian (free) Formats supported: AVI, DIVX, FLV, MKV, GVI, VP6, and VFW
Flip4Mac WMV ($29) Formats supported: Windows Media video and audio

Here is a list of applications that are useful in repurposing non-MPEG-4 files to the proper iPhone specs:

Handbrake 0.9.4 (free) Converts DVDs to MPEG-4, including iPhone output.
Miro Video Converter 2.2 (free) Converts almost anything to MPEG-4, including iPhone output.
CosmoPod ($12) Downloads and converts YouTube and other Flash video to MPEG-4 iPhone output.
QuickTime X Player (free) Converts anything it can play (see components above) to iPhone format.
MacOS X Automator
Movie Services (free) Converts andy QuickTime movie to iPhone format.

Here's a screencast medley of these applications at work repurposing video that will be playable in the iBooks app on iOS devices.



Friday, September 17, 2010

My proposal for a presentation to the 39th University System Annual Computing Conference entitled, "Creating and Publishing eBooks Using the EPUB Standard" has been accepted. This conference is not held in a hotel in some big city. Rather, it happens on the 1,452 acre Rock Eagle 4-H Center just outside Eatonton, Georgia. Here's the official site for the conference where you'll find all of the info on it that you might want.

Thus, I'll be holding forth on this topic for 45 minutes beginning at 8:30 AM on Thursday October 21 in the "International Paper 3" room. Not exactly the "Boom Boom" room but it will be a good experience I'm sure. Here is the abstract:

Creating eBooks using the EPUB standard is now within the grasp of faculty as well as any other subject matter expert with basic computer skills.  Additionally, publishing eBooks for consumption by students and others on desktop. laptop and mobile devices will soon be a drag and drop operation.  In addition to an overview of the eBook creation and publishing process, attendees will have access to a companion web site with links to in-depth information, tutorials and resources.

See you at the Rock!