IOS播放本地视频

使用IOS播放视频,可以简单的用AVPlayerAVPlayerViewController来实现。

如下:

let videoURL = NSURL(fileURLWithPath: path)
  let player = AVPlayer(URL: videoURL)
  let playerViewController = AVPlayerViewController()
  playerViewController.player = player
  self.presentViewController(playerViewController, animated:
阅读全文