开发者

iPhone media player framework : play multiple movie files seamlessly

I am using the media player framework's MPMoviePlayerController to play local (on device) m4v files. Depending on user's selection, I want to be able to play multiple movies one after the other seamlessly.

To do this, I queue up the movies in an array and in my observer method that is called on the MPMoviePlayerPlaybackDidFinishNotification event which is triggered after one movie finishes, I play the next movie in the queue.

However, this is far from seamless. After each movie finishes, the iphone view transitions back to the base view from which the movieplayer was called a开发者_如何学JAVAnd then picks up the movie called in the observer method (moviePlayBackDidFinish).

Is there a way to make the movies play one after the other seamlessly without breaking to transition back to the base view?

Just to be very clear, all the movies are local and bundled with the app as resources, not being streamed from anywhere.


You can use AVMutableComposition. It combines media data from multiple file-based sources in a custom temporal arrangement, in order to present or process media data from multiple sources together.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜