Looks like the latest version of the WebRadioApp demo is from a CocoaConf Boston class last year. I just ran it in the iPhone 6 simulator and it still works, so maybe start there:
I don't really have any slides or anything to go with it. The basic idea is that you start downloading with an NSURLConnection (yeah, I wrote this before NSURLSession), hand the raw NSData's over to an AudioFileStreamRef, it calls back to a properties proc (which receives format and "ready to produce packets"), and a packets proc (which feeds the AAC or MP3 packets to an AudioQueue for playback).
If you need a look at the LPCM data before it gets played, then we're talking about integrating an Audio Queue Processing Tap.
—Chris
Hi Chris,
Yes it is a streaming app. After converting the AAC file to LPCM, I run it through my main app which does some content analysis on the audio.
Does your sample allow me to avoid saving the received file data to a disk file? That sounds like it matches what I am trying to do. I'd much appreciate any pointers or sample code you could provide.
Richard
|