내 앱에는 여러 탭이있는 탭보기가 있으며, 그 중 하나에는 클릭하면보기에 동영상 스트림을 표시하려고하는 버튼이 있습니다. 이 코드를 가지고 :다른보기에서 동영상 스트림 열기
NSString *moviePath = @"http://10.0.0.4/prog_index.m3u8";
theMovie = [[MPMoviePlayerController alloc] initWithContentURL:[NSURL URLWithString:moviePath]];
[theMovie.view setFrame:CGRectMake(0, 0, (self.view.frame.size.width), (self.view.frame.size.height))];
theMovie.view.backgroundColor = [UIColor grayColor];
theMovie.view.tag = 9999;
[self.view addSubview:[theMovie view]];
[theMovie play];
보기가 나타나지만 비디오가 시작되지 않습니다. 뭐가 잘못 되었 니? 누군가 힌트를주세요.
감사
그러나 관련 질문에서 재생 목록 파일을 재생할 수 있으며 나머지는 MPMoviePlayerController라고 말합니다. –
네 말이 맞아, 나는 이것에 완전히 틀리다. 코드에 무엇이 잘못되었는지 알아 내려고 노력 중이다. – ender
나는 내 anser를 편집 해 봤어. – ender