I am trying to play audio files from the iPod library without any delay from calling 'play' to when the actual music starts. I tried using the MPMusicPlayerController, but sometimes there is a delay, even a couple of seconds. I 开发者_运维技巧also tried calling 'play' and 'pause' before the actual play, but it didn't help.
I tried the same using AVPlayer, but the same problem. When I tried using AVAudioPlayer and calling its 'prepareToPlay' it worked great! absolutely no delay, but the AVAudioPlayer cannot play music from the iPod library.
Unfortunately, nor the AVPlayer or the MPMusicPlayerController have this method.
Any help would be appreciated.
Gili.
精彩评论