Hi :
Using the code below, I can't play large video files, my app crash and I received this message "level 1 memory warning". The video files (mp4) are 205MB
Note: this is only happen in iphone
-(IBAction)playVideo

id)sender {
NSBundle *bundle = [NSBundle mainBundle];
NSString *moviePath = [bundle pathForResource:@"FUTURAMA_S1D1-11-6" ofType:@"mp4"];
NSURL *movieURL;
if (moviePath)
{
movieURL = [NSURL fileURLWithPath:moviePath];
}
if (movieURL != nil) {
moviePlayer = [[MPMoviePlayerViewController alloc] initWithContentURL:movieURL];
moviePlayer.moviePlayer.scalingMode=MPMovieScaling ModeAspectFit;
moviePlayer.moviePlayer.shouldAutoplay = YES;
moviePlayer.moviePlayer.controlStyle = MPMovieControlStyleEmbedded;
[[NSNotificationCenter defaultCenter] addObserver:self
selector:@selector(moviePlayBackDidFinish
name:MPMoviePlayerPlaybackDidFinishNotification
object:moviePlayer];
[self presentMoviePlayerViewControllerAnimated:moviePlay er];
}
}
Thanks