How to use Extended Audio File Services: ExtAudioFileRead to Performs a synchronous, sequential read operation on an audio file.
NSString *filePath = [[NSBundle mainBundle] pathForResource:@"theme"
ofType:@"mp3"];
NSURL *fileURL = [[NSURL alloc] initFileURLWithPath:filePath];
audioPlayer = [[AVAudioPlayer alloc]
initWithContentsOfURL:fileURL error:nil];
[fileURL release];
How i can Performs a synchronous, sequential read operation on theme audio file. Currently have AVFoundation.Framework and should i add CoreAudio.Framework too.
To use Extended Audio File services, you’ll need to link to
AudioToolbox.frameworkOpening and reading a file using this API is fairly involved. There’s some good information here, and the Documentation.
For my part, I’ve found the headers in
AudioToolbox.frameworkto have the best documentation. SeeExtAudioFile.h