iOS swift streaming app does not play music in background mode
问题 My app is running fine but as soon the screen safe is on or the doing something else on the iphone the stream stops. I activated the background modes "is playing audio" but it does not helps. This is my ViewController.swift import UIKit import MediaPlayer class ViewController: UIViewController { let player: MPMoviePlayerViewController = MPMoviePlayerViewController(contentURL: NSURL(string: "http://url to my stream")) override func viewDidLoad() { super.viewDidLoad() // Do any additional setup