I’m shipping a quicktime .mov video encoded with H.264, low quality. It’s about 2 MB small. Not full-screen.
The video must be embedded in a view. Is MPMoviePlayerController state-of-the-art for this purpose, or are there better (easier) options?
It’s important that the video plays in the non-fullscreen view, and that playback controls are either overlayd on top of the video or can be customized. I’m not sure if MPMoviePlayerController is good for this.
MPMoviePlayerControllerandMPMoviePlayerViewControllerare two classes you can use to play video in iOS SDK.MPMoviePlayerViewControlleris supposed to be presented as a modal view controller, so it’s not what you’re looking for.MPMoviePlayerControllerplays the video onto a view (UIView) which you can add in your view hierarchy, which is what you need.Be aware that on iOS < 3.2,
MPMoviePlayerControlleris fullscreen only (not a problem if you’re targeting 3.2 or newer).Although you can do customizations by adding your own buttons (for play, pause and stop controls), sliders (for volume and seeking) and labels (to display duration and length), Apple encourages the use of standard video controls. The reason is that users are used to the standard UI (which is also pretty advanced, supporting features such as fine scrubbing), plus if Apple ever adds new features to it in future versions of iOS, you won’t have to add them yourself in your customized implementation.