Metering background music
The CDAudioManager class wraps the AVAudioPlayer class. Using this class gives us access to lower level audio functions.
In this recipe, we will dynamically read the average level and peak level of background music currently playing. We can use this information to sync or cue animations.