在我的应用程序中,我想继续在后台播放视频。所以我不想在视频中播放和停止视频和透明线。
我尝试了以下代码:
self.videoController = [[MPMoviePlayerController alloc]initWithContentURL:[NSURL fileURLWithPath:@"/Volumes/Data/Monika/Projects/Salon/Salon/Salon/Images/video/salon.mp4"]];
[self.videoController setControlStyle:MPMovieControlStyleDefault];
self.videoController.view.frame=CGRectMake(0,0, 320, 202);
[self.videoplayview addSubview:self.videoController.view];
[self.videoController play];
答案 0 :(得分:4)
只需将控件样式设置为MPMovieControlStyleNone,如下所示:
[self.videoController setControlStyle:MPMovieControlStyleNone];