我已经彻底扫描了谷歌,这是他们在mpmovieplayercontroller上播放avmutablecomposition的方法,他们必须使用URL初始化,所以我猜真正的问题是,他们是avmutablecomposition的临时URL还是我们可以创建一个avassetexportsession如果用户不喜欢它可以删除呢?
答案 0 :(得分:0)
使用iOS 8.0,您可以使用AVPlayerViewController - https://developer.apple.com/library/prerelease/ios/documentation/AVFoundation/Reference/AVPlayerViewController_Class/index.html
AVPlayerViewController *playerVC = ....; //initialize the playerViewController
AVPlayerItem *playerItem = [AVPlayerItem playerItemWithAsset:[mutableComposition copy]]; //make an immutable copy of the mutableComposition
AVPlayer *player = [AVPlayer playerWithPlayerItem:playerItem];
[playerVC setPlayer:player];