I have to develop a player in iPhone that play videos. I have not much background in video encoding and signal encoding. When I test some .mp4 and .mov file I see that only the video with resolution that fits the iPhone screen size can be played and larger size cannot be played. Are there any solutions to play all the movie size on iPhone in that case. Please give me some instruction. Many thanks in advance. The code to play the video is below:
NSURL *url = [NSURL URLWithString:@"http://192.65.123.108/test1.mov"];
//this movie has size of 480x272 can be played, other larger resolution cannot be played
_moviePlayer = [[MPMoviePlayerController alloc]
initWithContentURL:url];
[[NSNotificationCenter defaultCenter] addObserver:self
selector:@selector(moviePlayBackDidFinish:)
name:MPMoviePlayerPlaybackDidFinishNotification
object:_moviePlayer];
_moviePlayer.controlStyle = MPMovieControlStyleDefault;
_moviePlayer.shouldAutoplay = YES;
[self.view addSubview:_moviePlayer.view];
[_moviePlayer setFullscreen:YES animated:YES];
I don’t think there is a way to do this, unless you can scale the video down before you play it. It would probably be inefficient though.