Chapter    5

Playing and Recording Audio Files

In this chapter, you will explore how to use audio resources in your app by building applications to play and record audio using iOS’s AVFoundation framework for audio-visual tasks. Much like image files, audio is stored as binary data, and must be decoded before your application can use it. A huge difference, however, is that audio files are stored as a stream of data, indexed by time, rather than a stream that represents one static image. As is so often the case, “there’s an API for that,” and you will take advantage of iOS’s built-in audio player and recorder classes to build your apps. Just as you dealt with images, you will see how AVFoundation takes care of the details, allowing you to focus ...

Get Beginning iOS Media App Development now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.