Teaching and Learning Resources by Peter Pappas

How to Add Scalable Vector Graphics (SVG) Images to iBooks Author

iBA SVG enlargedHere’s another great iBooks Author (iBA) “how to” – cross posted from Dr. Frank Lowney (Projects Coordinator, Digital Innovation Group @ Georgia College). See Frank’s original post a watch his demo video here. Frank writes:

The primary advantage of Scalable Vector Graphics (SVG) files is that a very small file can be scaled up to yield large images without the aliasing (jaggies) that appears when a bitmapped graphic is scaled up. SVG files are resolution independent, usually non-photographic and carry the suffix *.svg. There are lots of free SVG files available on the Internet and there are many applications for creating SVG files such as the free, open source Inkscape. For an excellent primer on vector graphics, see this Wikipedia article.

However, it is not possible to use SVG images directly in iBooks Author. If you attempt to drag and drop an SVG file onto an iBooks Author project, nothing will happen. You’ll get no error messages or feedback of any kind. Similarly, apps in the iWork suite (Pages, Keynote and Numbers) will also refuse to accept SVG files. Since it is important to keep the size of iBooks Author output low for easy downloading and to avoid the 2 GB limit in the iBookstore, we need to pursue this further.

The iBooks Author application has its own Text, Shapes and Graphs menus with which a number of vector graphics can be created. Another option is to use the vector graphics created by Keynote, Numbers and Pages. These can be copied and pasted directly into an iBooks Author project. Graphics created in iBooks Author or any of the iWorks suite applications are vector graphics in PDF containers, not SVG files. PDF files can contain text, bit-mapped graphics and vector graphics. [The $99 OmniGraffle application is a considerably more sophisticated graphics toolset and is capable of exporting both SVG vector drawings and PDF vector images. The latter are compatible with iWork suite and iBooks Author.]

That’s useful but there is an Internet full of already drawn SVG images that are in the public domain or CC licensed. It would be a shame not to have access to that vast library of free vector images. The trick is to use this free on-line conversion service to convert SVG to PDF and then drag and drop that PDF directly into an iBooks Author project or into one of the iWork apps or OmniGraffle for further manipulation.

Download an *.ibooks file here that shows how vector graphics created in iBooks Author compare with vector graphics converted from SVG files.

Vector image creation - Cheat Sheet
Vector Image Creation and Editing – Cheat Sheet was created by First Site Guide Team>.

How to Use iAD to Create an External Video Widget for iBA

iAd

The three iBooks in my WWII Homefront USA series started with an idea for single iBook. Then as I began to uncover so many long-forgotten videos,  I realized there was a trade off between creating a media-rich iBook and keeping the file size manageable.  I considered keeping file size smaller by simply linking to the videos from the iBook. (I would provide a hyperlink in the iBook and the reader would tap on it to be led to the video on YouTube or Archive.org.) But that required that the reader be on a network to view the iBook’s videos. And I didn’t think that a hyperlink was a very visually appealing approach.

Use iAd Producer to create a high quality HTML widget for iBooks Author without writing a single line of code.

So my single iBook project idea turned into three iBooks with file sizes running roughly 600MB each. I carefully edited the videos and used file compression – but the 13-18 videos in each iBook demanded a lot of file space.

I was pleased to hear that my go-to guy for iBooks Author –
Dr. Frank Lowney (Projects Coordinator, Digital Innovation Group @ Georgia College) had posted a video how-to for using iAd Producer to create external video widgets of iBooks Author projects. No coding required!

He agreed to let me cross post his work here with a slightly edited version of his original screencast. 

Frank posts – The iAd Producer application from Apple has grown considerably since its inception. Originally, it was a highly specialized application that created advertisements for mobile devices from Apple. Those iAds were composed of sophisticated HTML, CSS and Javascript.

Since that inception, it has been expanded to create iTunes LPs for music albums sold in the iTunes Store and iTunes Extras for video sold in the iTunes Store. These, too, rely upon HTML, CSS and Javascript web technologies. Most recently, iAd producer has added iBooks Author HTML widgets to its repertoire. Thus, the following screencast tutorial showing how easy it is to use iAd Producer to create a high quality HTML widget for iBooks Author without writing a single line of code.

This example focuses on creating an HTML widget that plays a video hosted on an external server. This keeps the size of your *.ibooks file down making for quicker downloads and avoiding becoming a burden to iPads already nearly filled to capacity with other books and media.

You can see Frank original video here - it includes comparison of various video strategies for iBooks Author. Download the example book to an iPad to get an even better view of how this looks and feels in the hands of your audience.

Download iAd Producer (free developer registration required)

I highly recommend  Frank’s iBook The Coming ePublishing Revolution in Higher Education
on iTunes. It’s an insightful guide to etextbook revolution – winners, losers, and the factors that will determine the outcome. (67 pages, 20 graphics, 28 media files, 25 video files and 5 interactive widgets.) A bargain at only $0.99!

Why I Haven’t Upgraded to iBooks Author 2.0

Note: Since I first publishing this post, I took the leap and updated to iBA 2.0. (Of course, I had to because iTunes only accepts new books created in iBA 2.) I published three books in the new software and was also able to successfully open iBA 1.0 files in 2.0 and even copy widgets and other content from 1.0 to 2.0.

Over the last few months I’ve been blogging regularly about my iBooks Author (iBA) learning curve and the production of my first iBook. Along the way I have come to rely on the advice of Dr. Frank Lowney Projects Coordinator, Digital Innovation Group @ Georgia College.

BTW – Frank published The Coming ePublishing Revolution in Higher Education on iTunes. It’s an insightful guide to etextbook revolution – winners, losers, and the factors that will determine the outcome. (67 pages, 20 graphics, 28 media files, 25 video files and 5 interactive widgets.) A bargain at only $0.99!

Frank’s been most generous with his time and advice on technical aspects of formatting videos for use in iBooks Author. Recently he contacted me about some troubling features in the new iBA 2.0 which I summarized in a post – Read This Before You Upgrade to iBooks Author 2.0. As a result of that post, I was contacted by Jay Welshofer (Apple’s Senior Product Manager for iBooks Author and Keynote) who has been working with Frank to better understand the video encoding issues with iBA 2.0.

Rather than expose my veneer of understanding of video technology, let me quote some of my correspondence with Frank so that others can benefit.

I begin with three questions I posed to Frank about iBA 2.0 video optimizer ~ Frank’s replies:
1. Does it do an acceptable job on quality? (a bit of a change from your earlier appraisal)
~ Yes, the quality is quite good if the source is good. I haven’t yet done a lot of testing with lower quality source but that’s on the todo list.

2. Does it increase file size ?
~ Absolutely. The bloat is up to three times the size of what Handbrake outputs with no appreciable difference in video quality.

3. Does it wipe out subtitle tracks
~ Every time. Alternate audio tracks and chapter tracks too. Of course, chapter tracks are not relevant to iOS video except in the Videos.app which has an interface for chapters that is separate from playback. Older versions of quicktime presented chapters as a drop down menu in the controller which lends itself to all kinds of neat pedagogical uses.

To reinforce his point Frank ran a test video conversion comparing iBA 2.0 and Handbrake and supplied a video sample of each. He writes:

Dear Peter and Jay,
I have been unable to reliably replicate my initial report where video quality was significantly lessened by the IBA media optimizer. Actually, this optimizer does a pretty good job of maintaining video quality no matter what you throw at it.

However, there is still the problem of file size bloat that started this whole line of investigation back in the IBA v1 days. As you’ll recall, IBA would reject many videos and recommend re-encoding in QuickTime Player and that would create files 2-3 times larger. This was a concern to many IBA users due to the 2 GB limit on iBooks in the iBookstore.

Back then, the workaround was to tweak the output of more efficient systems such as Handbrake such that IBA wouldn’t reject them. Now, with IBA v2, the use of QuickTime is no longer optional and the file size bloat issue is with us again. The new workaround is to use the video replacement surgery tactic that I described earlier. It’s a bit more daunting than the earlier workaround because you could break the whole iBook just by getting the name of one video file wrong, a typo for example.

As promised, I’ve constructed a hardball case documenting this issue as follows. An executive summary in the form of a screencast comparing the iBooks Author encode to the Handbrake encode will have more general interest. Here it is:

The source file came from a “pro” level HD DV camera and was provided to us as a ~16 GB DVCPRO HD file at 720p. As you can see from the video, iBooks Author encoded this as a 1.5 GB file (causing a warning about the 2 GB limit) whereas Handbrake 0.98 (Apple TV 3 preset) produced a 532 MB file, a third of what IBA produced. Also evident in the video should be the fact that there is no discernible difference in size or quality.

BTW, I used QuickTime Player 7.6 for this demo because it can play two or more videos sychronously allowing much better qualitative analysis. QuickTime X Player cannot do this.

Read This Before You Upgrade to iBooks Author 2.0

Note: Since I first publishing this post, I took the leap and updated to iBA 2.0. (Of course, I had to because iTunes only accepts new books created in iBA 2.) I published three books in the new software and was also able to successfully open iBA 1.0 files in 2.0 and even copy widgets and other content from 1.0 to 2.0.

I recently published my first iBook Why We Fight: WWII and the Art of Public Persuasion.
It features over a dozen historic propaganda videos. I used iBooks Author 1.0 (iBA) to create the iBook, and with lots of advice from experts, I managed to create good quality videos of manageable file size.

Before I upgraded to iBA 2.0, I thought I’d do some research.
I’m glad I did, because it appears that the new iBA 2.0 “Media Optimization” feature has mixed reviews in video management. That early analysis comes from Dr. Frank Lowney, Projects Coordinator, Digital Innovation Group @ Georgia College. Frank spent many hours online answering my questions about importing videos into iBA 1.0 and I owe him a big thanks.

Here’s some of what Frank wrote about iBA 2.0 in his comment to a recent MacWorld review.

IBAv1 was terribly finicky about video. It rejected videos that played perfectly well in the Videos.app on iPad. The current optimization routine is an apparently a well intentioned correction of that finickiness.

… If you are writing a textbook or any kind of book containing video that requires providing soft subtitle tracks to address accessibility and other important goals or alternate audio tracks to reach a wider, multi-lingual audience, be aware that this optimizer will strip out those valuable assets without notice. Of concern to a wider group of authors is the violence done to certain videos by this “optimization” routine. Although it works quickly and does a reasonably good job on video that is already close to optimal, it wreaks havoc on video that is not. 

…The worst part is that you cannot revert to the old regime.

For more a detailed analysis see this thread in the Apple Support Communities Preventing iBooks Author Media Optimization where Frank comments: 

The optimization routine in iBooks Author 2.0 is well intentioned but the execution of those intentions is quite poor. In addition to bloating the size of your videos and, hence, your iBook, it can also degrade visual quality in dramatic fashion.
… With iBooks Author 1.x, I had figured out how to create very efficient and highly capable video that IBA will accept. This “feature” throws me and a lot of other capable people into a ditch.

I asked Frank if I can use his comments and he agreed, while noting he hasn’t had time “to do full range of tests and documentation that I prefer to do.” But his early reviews suggest that I’ll wait to upgrade. Who needs bloated files, lost subtitled tracks and poor video quality?

Read Nov 30th update

~~~~~~~~~~~~~~~~~~~~~~~~~~
Nov 9 Update from Frank Lowney:

Peter,

As you’ll recall, the caveat was that my findings re video in IBA 2 were preliminary and, therefore, subject to revision as I conduct more rigorous tests. I may well have to eat some of those earlier words. I’m still nowhere near a definitive opinion but I did manage to do a comparison between videos submitted to IBA and what they looked like after the “optimizer” got through with them.

The way to do that is to change the suffix of an *.ibooks file to zip and then use something like the free Stuffit Expander to expand the archive and reveal its folder structure and enable examining the contents. Video files are all in /OPS/assets/media/.

So I created five new videos for my iBook, loaded them into IBA, let the optimizer have at them and then compared the file size of the originals with what I found inside the *.ibooks file. I was surprised and pleased to find that four out of five were pretty much the same as the originals in both file size and quality. The odd one was 7.6 MB in the original and 8.2 MB in the *.ibooks file which is not huge. IBA apparently jacked up the data rate a little.

Of course this was a “soft ball” since the source came out of the recently released ScreenFlow 4 using a custom settings designed to be optimal for iPad (a multi-pass encode at 1024×768 using H.264 in a MOV container). Except for changing the container from .mov to .m4v, everything was the same in the *.ibooks file: bit-rate, frame rate, height, width, etc. So if you give IBA something that it expects and respects, it does no harm.

I’ll start throwing hard balls in the coming days and we’ll see what happens.

I’m sticking to what I said about soft subtitle tracks and alternate audio tracks. These are incredibly important in an educational environment in terms of Section 508 and 504 compliance. As well, being able to offer multi-lingual access is critical to the success of on-line learning. What IBA’s “optimizer” does to them is indefensible. There seems to be a contingent at Apple who think that Closed Captions, a throwback to analog TV broadcasting, is sufficient but they are dead wrong. It relies on a binary format that can only be created by expensive and difficult to use software (go ahead and price MacCaptioner) as contrasted with SRT, ASS, etc. that anyone can create with a simple text editor.

So, for people who aren’t concerned about subtitles and alternate audio tracks, the upgrade to IBA 2.0 appears to me to be a good move. The new widgets are awesome, especially the scrolling sidebar which looks a lot like what I described in an enhancement request that I submitted. The only people for whom this is a show stopper are the folks that are prepping video for iBooks and working for institutions and corporations that simply must address these accessibility issues. Indies like you and I can ignore these issues for the time being. The stuff I do at work is another story altogether.

More later and thanks for being a great sounding board.

Scroll to top
%d bloggers like this: