Por que meu MPMoviePlayerController não é reproduzido?
Eu estou tentando obter um arquivo de vídeo .mov básico para jogar usando o código abaixo, mas quando o botão que eu atribuí a ação é pressionado, a única coisa que aparece é o quadro preto, mas nenhum vídeo é reproduzido. Qualquer ajuda é apreciada. Obrigado.
@implementation SRViewController
-(IBAction)playMovie{
NSString *url = [[NSBundle mainBundle]
pathForResource:@"OntheTitle" ofType:@"mov"];
MPMoviePlayerController *player = [[MPMoviePlayerController alloc]
initWithContentURL: [NSURL fileURLWithPath:url]];
// Play Partial Screen
player.view.frame = CGRectMake(10, 10, 720, 480);
[self.view addSubview:player.view];
// Play Movie
[player play];
}
@end