Hi seen many tutorial but couldn't find the right workable answer. I need to play audio and video file from my webservice, for this I want to download the file and play it in the app, seen tutorial for avPlayer nothing workable. Please provide link or guide how to do this.
Asked
Active
Viewed 222 times
1
-
what is te extension of the audio file? – Codesen Oct 19 '12 at 06:21
-
are you trying to code a live streaming or the downloaded audio/video file – Shineeth Hamza Oct 19 '12 at 06:23
-
try this thread, it may help you: http://stackoverflow.com/questions/10245345/how-to-download-audio-video-files-from-internet-and-store-in-iphone-app – Shineeth Hamza Oct 19 '12 at 06:25
1 Answers
0
Use MPMoviePlayer, as this can open network streams and despite the name works with audio. The only thing is this pops up the modal player with controls.
First Download the network file using NSURLConnection and store it locally, then use AVAudioPlayer to play the local file.

Codesen
- 7,724
- 5
- 29
- 31