Chapter 11. Media: images and the camera

 

This chapter covers

  • Accessing and manipulating images
  • Using the camera
  • Creating a simple collage application
  • Using AirPrint for images

So far, our focus has mainly been on text. Sure, we’ve displayed the occasional UIImage, such as the mountain drawing in the previous chapter, but we’ve considered only the simplest means for doing so.

The iPhone, iPod Touch, and iPad offer an experience that’s potentially much richer and more engaging. Cameras, a microphone, a complete library of photos, and a speaker are just some of the utilities built into these devices. Less the camera, the first-generation iPad contains all the aforementioned libraries. In this chapter and the next, we’ll look at these features as part of a general exploration of media. We’ll provide deep coverage of images as well as how to use the camera.

More complex questions are beyond the scope of this chapter. We’re saving the topic of image editing for a later chapter, when we look at the graphic libraries.

11.1. An introduction to images

We’ve touched on using images a few times, beginning in chapter 3, where one of the earliest SDK examples included an image. You’ve created a UIImageView in Xcode, attached it to a filename, and not worried about the details.

We’re now ready to consider the details. We’ll look at some of the options available when you dive into Xcode.

11.2. Drawing simple images with Core Graphics

11.3. Accessing photos

11.4. Collage: an image example

11.5. Printing images

11.6. Summary