Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

MPMoviePlayerController Add custom Play button

Tags:

ios

iphone

Currently i am working on a iPhone Application Which is displaying video. I have used MPMoviePlayController to load the Video from the local folder.

Can we customize the Standard media player ? What i want to do is to hide all the standard elements (Play, Forward, Rewind, Done) and just to build the player with a single play button with a customized image . Can anybody help me ?

like image 428
BigAppleBump Avatar asked Feb 12 '12 12:02

BigAppleBump


1 Answers

You can surely add custom controls for MPMoviePlayerController. For that first hide existing controls using, MPMovieControlStyle, set this to MPMovieControlStyleNone

Now add your custom control buttons and handle all the MoviePlayer events over there, like;

  • Play
  • Pause
  • Stop
  • Prev
  • Next, etc.
  • Or you can add your own controls like jump to this time (+10 sec, +20 sec), movie speed control (1x, 2x, ..), etc.

Hope this will be useful for you.

like image 186
Mrunal Avatar answered Oct 06 '22 19:10

Mrunal