bookcoverI’m very happy to announce my new book, Learning AV Foundation, is available for pre-order from InformIT. Enter MCCUNE1808 to receive a 35% discount. This is the book I wish I had a few years ago, and I hope it will provide you with the understanding and inspiration to build amazing media applications for iOS and OS X!

This book is not intended to be a definitive reference guide covering every aspect of the framework, but instead focuses on the most relevant parts of the framework to lay the foundation that will empower you to be fully comfortable with the concepts, features, and conventions used throughout. Here are the details of the topics covered in the book:

  • Chapter 1, ”Getting Started with AV Foundation”—This chapter will help you take your first steps with AV Foundation. It deconstructs the framework to help you gain a better understanding of its features and capabilities. This chapter also provides a high-level overview of the media domain itself and covers topics such as digital sampling and media compression. An understanding of these topics will be helpful throughout the book.
  • Chapter 2, “Playing and Recording Audio”—AV Foundation’s classes for playing and recording audio are some of its most widely used features. In this chapter we discuss how to use the framework’s audio classes, and you’ll put them into action building an audio looper and voice memo applications. We also cover how to use audio sessions to help you provide a polished audio user experience to your apps.
  • Chapter 3, “Working with Assets and Metadata”—Much of the framework is built around the notion of assets. An asset represents a media resource, such as a QuickTime movie or an MP3 audio file. You learn to use assets and how to use the framework’s metadata features by building a metadata editing application.
  • Chapter 4, “Playing Video”—Playing video is one of the most essential tasks AV Foundation performs. It’s a primary or supporting use case in many media apps. You gain a detailed understanding of how to use the framework’s playback features to build a custom video player with full transport controls, subtitle display, and Airplay support.
  • Chapter 5, “Using the AV Kit Framework”—AV Kit is a new framework introduced in Mac OS X 10.9 and now in iOS 8. It enables you to quickly build AV Foundation video players with user interfaces matching QuickTime Player on OS X and the Videos app on iOS. This can be a great option if you want to build players maintaining fidelity with the native operating system while retaining the full power of working directly with AV Foundation’s video APIs covered in Chapter 4.
  • Chapter 6, “Capturing Media”—This chapter provides an introduction to the framework’s audio and video capture features. You learn to use these features to control the built-in camera hardware available on iOS devices and modern Macs. This is one of the most widely used areas of the framework, and it can help you build powerful, modern camera capture applications.
  • Chapter 7, “Using Advanced Capture Features”—This chapter covers a variety of advanced capture topics. You learn to use metadata capture to perform barcode scanning and face detection. You learn to use the advanced zooming capabilities provided by the framework. You also learn to enable high frame rate capture, which is great for adding slow motion effects to your videos. We also discuss how to integrate with OpenGL ES to process the video samples captured by the camera, which opens up a world of possibilities.
  • Chapter 8, “Reading and Writing Media”—AV Foundation provides a lot of high-level functionality, but the framework never hides the lower-level details from you when you need it. In this chapter we discuss the framework’s low-level reading and writing facilities that can enable you to process the media in any way you want. We discuss how to read audio samples from an asset and render them as an audio waveform. We also look at applying real-time video effects using the camera capture APIs.
  • Chapter 9, “Composing and Editing Media”—In this chapter we begin our exploration of the framework’s media editing features. This is one of the most powerful features of the framework, and it enables you to create new media by composing and editing media from a variety of sources. In this chapter you begin building the book’s most advanced application, 15 Seconds, which is a video editor similar to an application like iMovie for iOS.
  • Chapter 10, “Mixing Audio”—An important part of building media compositions is learning how to mix multiple audio tracks. You learn how to use mixing techniques such as audio fades and ducking that will help you add polish to your audio presentation.
  • Chapter 11, “Performing Video Transitions”—Video transitions are commonly used to indicate a change in location or storyline, and AV Foundation provides robust support for applying video transitions to your compositions. In this chapter you learn to use the framework’s video composition to control the compositing of multiple video tracks in your composition. You’ll put these features into action to add dissolve, push, and wipe transitions to the 15 Seconds app.
  • Chapter 12, “Layering Animated Content”—This chapter discusses how to add titles, lower thirds, and other animated overlay effects using the Core Animation framework. You’ll see how to use Core Animation to build animation sequences that seamlessly synchronize with your video playback. We also discuss how to incorporate these same effects in your final exported videos.

[ 1 comment ]

Learning AV Foundation Book in Development

by Bob McCune on November 8, 2013

Learning AV Foundation - Rough CutI mentioned earlier in the the year that a major focus of mine has been to help better educate people about AV Foundation. I’m happy to announce I’m working on a new book called Learning AV Foundation that will provide a comprehensive guide to mastering the framework. The book provides a hands-on guide to working with the various features of the framework and focuses heavily on building real-world applications for iOS and OS X.

The book is still early in its development, but the publisher has made a Rough Cut version available on Safari Books Online. The first 5 chapters are currently available and new ones will be added as the content is developed. A Rough Cut chapter is the raw, unedited version, so if you notice any errors or omissions, ping me here or leave a comment on the book’s page on Safari Books Online.

Table of Contents

  1. Getting Started with AV Foundation
  2. Playing and Recording Audio
  3. Working with Assets and Metadata
  4. Playing Video
  5. Using the AV Kit Framework
  6. Capturing Media
  7. Using Advanced Capture Features
  8. Reading and Writing Media
  9. Composing and Editing Media
  10. Mixing Audio
  11. Performing Video Transitions
  12. Layering Animated Content

[ Comments on this entry are closed ]

CocoaConf Review

by Bob McCune on April 24, 2013

I had the great opportunity this spring to attend and speak at a couple different stops on the CocoaConf Spring Tour. I was at the event in D.C. in March and this past weekend returned from the event in San Jose. Now that I've had a couple CocoaConfs under my belt I thought I'd share my thoughts on the conference.

CocoaConf is a technical conference for iOS and Mac developers. The conference offers three concurrent tracks on a wide variety of topics so at any given time you're sure to find something of interest to you. The sessions offer a nice mix of introductory and advanced technical topics along with some great business-oriented talks as well. It has a really strong speaker line up featuring guys like Daniel Steinberg, Bill Dudney, Chris Adamson, and Jeff LaMarche, to name but a few. It was great to meet so many of the people whose writing and other works have been a big source of professional inspiration over the years.

One aspect of the conference I really like is the organizers put a cap on the number of attendees at a given event. Having a smaller group of attendees makes it much easier to meet new people, make new friends, and have meaningful conversations. I have learned a lot from the people I have met over the past couple months and listened to a lot of great stories along the way.

No mention of CocoaConf would be complete without discussing the family behind the conference. The Klein family puts on the conferences and does a great job of juggling the logistics while managing to make everything run like clockwork. It has been great getting to know Dave and his family a bit better. I can't say enough good things about the Kleins and am very thankful for their contributions to the Cocoa community.

The bottom line is CocoaConf is a great place to learn, connect, and grow. The CocoaConf Spring Tour may be over, but the bus will be rolling again this fall. Be sure to keep an eye on their website for upcoming dates. If you haven't been to CocoaConf before you owe it to yourself to go.

[ Comments on this entry are closed ]

Media Editing with AV Foundation

by Bob McCune on March 25, 2013

This past weekend I spoke at the CocoaConf event in DC. This was my first time attending CocoaConf so didn’t know what to expect, but I was very impressed by the format and quality of the conference and thought the organizers did an excellent job. I’m speaking again in San Jose next month and will post a more thorough review of the conference when I get back.

I gave a talk entitled “Composing and Editing Media with AV Foundation” where I dove into the details of the media creation and editing APIs. This is one of the more interesting areas of AV Foundation, but it is also the least documented which makes it particularly difficult to learn. Hopefully, this session and its associated sample app will make it easier for others to get started.

You can find the materials for the talk here:

Speaker Deck: Composing and Editing Media with AV Foundation

Slideshare: Composing and Editing Media with AV Foundation

GitHub: AV Foundation Editor

I’ll be giving this talk again next month so I look forwarding to seeing you at CocoaConf San Jose!

[ Comments on this entry are closed ]

Learning AV Foundation – Slides & Code

by Bob McCune on March 14, 2013

Tonight I gave an updated version of my “Learning AV Foundation” talk at the MN CocoaHeads meeting. In a rare move I actually posted my slides and sample code before I gave the talk. You can find the materials here:

Speaker Deck: Learning AV Foundation

Slideshare: Learning AV Foundation

GitHub: AV Foundation Demos

Thanks to everyone who turned out tonight. You guys continue to make the MN CocoaHeads groups one of the biggest and best CocoaHeads groups in the country.

[ Comments on this entry are closed ]

Learning AV Foundation

by Bob McCune on March 11, 2013

AV Foundation is Apple’s advanced Objective-C framework for working with timed media in iOS apps. The framework, as we know it today, was first introduced in iOS 4 and has seen signficant additions and enhancements in both iOS 5 and iOS 6. Starting with Mac OS 10.7 it is also the default media framework for the Mac platform which means Apple is investing the bulk of its media engineering resources in its development. Clearly AV Foundation is important to Apple and if media matters to you and your applications, it should be important to you as well.

AV Foundation is a very impressive framework with a broad and powerful feature set. However, it’s not a particularly easy framework to learn to use. It’s quite large with many classes, functions, and protocols so simply understanding where to start can be a challenge. It also relies on a number of advanced language features such as blocks, KVO, and Grand Central Dispatch so it can be a lot to bite off if you’re just starting out with the Mac or iOS platforms. But the single biggest reason this is a difficult framework to learn is it is so poorly documented. The AV Foundation Programming Guide is badly out of date and the API docs can, at best, be described as sparse. My best guess as to why this is the case is that the development team’s technical writers are always on vacation at release time. This means the only real way to learn to use the framework is through a significant investment of time, lots of experimentation, and the use of one or more high blood pressure medications.

One of my recent goals is to help people better understand how to use AV Foundation. I started working on this last fall when I gave my “Learning AV Foundation” talk at 360|iDev. I’ll be giving an updated version of that talk this week at the Minnesota CocoaHeads meeting. I’ll also be giving a talk entitled “Composing and Editing Media with AV Foundation” at the CocoaConf stops in DC and San Jose in the coming weeks. As part of both talks I have sample apps that I’ll be releasing on GitHub that will illustrate how to make use of the framework.

I’ve got some additional things planned for later this year and will post more about those when I get a bit closer. I like to do at least one useful blog post a year so, who knows, maybe I’ll even find the time to write about the topic on my blog.

[ Comments on this entry are closed ]