我正在使用以下代码尝试在我的应用中显示YouTube电影。出现视频播放器,显示一秒钟的控件,然后电影播放器收回。该应用程序不会崩溃。任何想法如何使这项工作?在MPMoviePlayerViewController中显示YouTube电影 - iPhone
MPMoviePlayerViewController *mpViewController =
[[MPMoviePlayerViewController alloc]
initWithContentURL:[NSURL URLWithString:@"http://www.youtube.com/watch?v=VKsVSBhSwJg"]];
[mpViewController shouldAutorotateToInterfaceOrientation:UIInterfaceOrientationLandscapeRight];
[[UIApplication sharedApplication] setStatusBarOrientation:UIInterfaceOrientationLandscapeRight animated:NO];
[self presentMoviePlayerViewControllerAnimated:mpViewController];
[mpViewController release];
啊,我已经读过了,但它的日期是2009年,所以我认为它现在可能已经升级了。 – Chris 2011-02-08 19:56:17