I’ve gone through a bunch of other examples, but I cannot get a video to load full screen in a viewController.
I’m able to get it to load… but not launch in full screen.
The code is below. Thanks!
-(void)viewWillAppear:(BOOL)animated {
NSString *filepath = [[NSBundle mainBundle] pathForResource:@"Sample" ofType:@"m4v"];
NSURL *fileURL = [NSURL fileURLWithPath:filepath];
MPMoviePlayerController *moviePlayerController = [[MPMoviePlayerController alloc] initWithContentURL:fileURL];
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(moviePlaybackComplete:)
name:MPMoviePlayerPlaybackDidFinishNotification object:moviePlayerController];
[moviePlayerController.view setFrame:CGRectMake(0, 0, self.view.frame.size.width, self.view.frame.size.height)];
[self.view addSubview:moviePlayerController.view];
moviePlayerController.fullscreen = YES;
[moviePlayerController play];
}
- (void) movieFinishedCallback:(NSNotification*) aNotification {
MPMoviePlayerController *player = [aNotification object];
[[NSNotificationCenter defaultCenter]
removeObserver:self
name:MPMoviePlayerPlaybackDidFinishNotification
object:player];
[player autorelease];
}
Edit: Full screen fixed… I just had to add: moviePlayerController.controlStyle = MPMovieControlStyleFullscreen;
Now it adds an odd image to my status bar.. see attached photo.

I don’t know what you mean by
fullscreenmeans, but I normally see this linewritten with
boundsas an argument like thisor
depending on what type of object
selfis.