我有一个视频,效果很好。
let AVPlayerVC = AVPlayerViewController()
func setupCustomPlayer() {
AVPlayerVC.view.frame = self.view.frame
AVPlayerVC.view.sizeToFit()
AVPlayerVC.showsPlaybackControls = false
self.view.addSubview(AVPlayerVC.view)
let videoURL = NSURL(string: "http://videourl")
let player = AVPlayer(url: videoURL! as URL)
AVPlayerVC.player = player
AVPlayerVC.player?.play()
}
播放视频时,我可以使用AV播放器播放声音文件(mysoundfile.m4p)吗?如果没有,那么替代解决方案是什么。