Discussion Forums  >  Plugins, Customizing, Source Code

Replies: 3    Views: 95

Alex@TM
Apple Fan
Profile
Posts: 956
Reg: Dec 20, 2011
London, UK
10,560
11/28/15 03:03 AM (9 years ago)

Movie Player

Hi all, Does anyone know how to play MP4s that are contained within the project please? The last time i did this was years ago and my old code no longer works as mpmovieplayer has been depreciated. This was the code NSBundle *bundle = [NSBundle mainBundle]; NSString *moviePath = [bundle pathForResource:@"Ian Holloway" ofType:@"mp4"]; NSURL *movieURL = [[NSURL fileURLWithPath:moviePath] retain]; MPMoviePlayerController *theMovie = [[MPMoviePlayerController alloc] initWithContentURL:movieURL]; theMovie.scalingMode = MPMovieScalingModeAspectFill; [theMovie play]; MPMoviePlayerViewController *moviePlayer = [[MPMoviePlayerViewController alloc] initWithContentURL:movieURL]; [self presentMoviePlayerViewControllerAnimated:moviePlayer]; Much appreciation for any help! Thanks
 
SmugWimp
Smugger than thou...
Profile
Posts: 6316
Reg: Nov 07, 2012
Tamuning, GU
81,410
like
11/28/15 04:11 AM (9 years ago)
About a year or so ago, I did an App update for a client, which involved an Animated Home Menu Screen. https://www.buzztouch.com/forum/thread.php?tid=8C5DA5CE493031574B680FF Although it's using an animated gif, the original design was using either a mov or an mp4... Either way, you should be able to use those in a webView. Cheers! -- Smug
 
Alex@TM
Apple Fan
Profile
Posts: 956
Reg: Dec 20, 2011
London, UK
10,560
like
11/28/15 04:50 AM (9 years ago)
Thanks Smug, i'll give it a go! Playing movies used to be so easy, finding any kind of reference to simple players now is virtually impossible. Thanks again, Alex
 
AlanMac
Aspiring developer
Profile
Posts: 2612
Reg: Mar 05, 2012
Esher, UK
37,120
like
11/28/15 03:00 PM (9 years ago)
I know html 5 can be used as a media player and works fine for mp4's. I used it in the VideoSnap plug-in to preview video's.
 

Login + Screen Name Required to Post

pointerLogin to participate so you can start earning points. Once you're logged in (and have a screen name entered in your profile), you can subscribe to topics, follow users, and start learning how to make apps like the pros.