It's hard for me to record anything other than linear PCM on the iPhone :-( The samples I found (SpeakHere SDK, Zdziarski and Sadun books and one on trailsinthesand.com) use linear PCM, but I would like to use the commonly used compressed format ( without ima4 or something else ...).
I just can't figure out how to set up sample code to be used, for example, AAC, MP3 or AMR. Any suggestions and tips on how to do this are greatly appreciated!
(By the way, I don’t think that an MP3 encoder or an AMR encoder is available due to licensing problems, but AAC exists, or ???)
Edit / Update: I came across the following text in Apple's “Application Programming Guide for the iPhone,” 2009-01-06, p. 137, section: Recording audio:
"You can record audio in any of the formats listed in the" Preferred audio formats on iPhone OS (p. 140) ", and as preferred audio formats on p. 140:" For compressed sound during playback one sound at a time and when you don’t need to play the sound at the same time as your iPod, use the AAC format packed in a CAF or m4a file. "
Thus, I interpret this as an explicit indication that it is indeed, not only possible, but even more preferable to record the sound in AAC format, wrapped in an m4a file, and this is exactly what I want. But still,I can’t achieve this ?!
Thanks, / John
source
share