O'Reilly logo

The Complete Idiot's Guide® To iPad and iPhone App Development by Troy Brant

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Playing Video

Now that you have covered how to save photos and video, let’s take a look at how to display these media to the user. A photo is simply a UIImage, which can be displayed using a UIImageView. Playing videos, however, requires that you use the MPMoviePlayerController class for playback.
MPMoviePlayerController is a controller that handles movie playback. All you have to do is give it a movie URL and tell it to play. The class can play any movie you can already play on your phone. This typically means files with extensions .mov, .mp4, .mpv, and .3gp are supported.
427
CRASH AND LEARN
You must add the MediaPlayer framework to your project ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required