Hello Guys ,
I am playing an video from url using MPMoviePlayerViewController class and it is working fine in all version of 3.(3.0,3.1,3.1.2,3.1.3)but in iOS4 video is not playing ? Have any one track this issue ?
thanks
Hello Guys ,
I am playing an video from url using MPMoviePlayerViewController class and it is working fine in all version of 3.(3.0,3.1,3.1.2,3.1.3)but in iOS4 video is not playing ? Have any one track this issue ?
thanks
After struggling 3 to 4 hrs. i Found out the solution of the issue. Here is the solution:
MPMoviePlayerViewController *mpViewController = [[MPMoviePlayerViewController alloc] initWithContentURL:videoUrl];
[self presentMoviePlayerViewControllerAnimated:mpViewController];
[mpViewController.view setCenter:yourView.center];
[mpViewController release];
Cheers !!!!
Hi Both,
This is exactly what I've been looking for but need a tiny bit more guidance if possible!?
My code is:
NSString *st1 = [[NSBundle mainBundle] pathForResource:@"ScreenRecording" ofType:@"mov"];
NSURL *u = [[NSURL alloc] initFileURLWithPath:st1];
MPMoviePlayerViewController *mp = [[MPMoviePlayerViewController alloc] initWithContentURL:u];
[self presentMoviePlayerViewControllerAnimated:mp];
However the video doesn't play, it simply closes the app on button tap (where this code exists)! - It'll be obvious I'm sure but what am I doing wrong!
Thanks so much in advance.
Chris.