Search code examples
iphoneaudiostreamingreachabilityhttp-live-streaming

iPhone SDK - HTML Live Streaming for audio


I've been developing an iPhone application that streams audio using Matt Gallagher's audio streamer found here: GitHud: AudioStreamer

However, I'm having some problems when the iPhone loses internet connection because the stream cuts out and doesn't reconnect until the user actually presses the play button again. I've even tried using the reachability classes from Apple to try and automatically stop and reconnect the stream but this isn't working 100%.

I've been reading around on the internet and I've found something called HTTP Live Streaming that can supposedly be used to stream audio on the iPhone. However, I can't seem to find any examples of how to use this, therefore can anyone help me by given a brief description any any source that might help to get this working please?

Thanks in advance, Luke


Solution

  • Not enough detail for me to answer this entirely, but I use a set of calls to be notified of reachability changes.

    When I get a failure, I change the play image to stop. I then wait for a notification that the network is back and then programmatically press play for the user.