AVQueuePlayer を作成し、いくつかのビデオ アイテムを追加します。アプリを実行すると、ビデオのサウンドは再生されますが、ビデオは表示されません。ビデオが表示されない理由はわかっています。ビューに AVQueuePlayer を追加する方法がわからないためです。私を助けてください
NSString *firstVideoPath = [[NSBundle mainBundle]
pathForResource:@"3" ofType:@"m4v"];
NSString *secondVideoPath = [[NSBundle mainBundle]
pathForResource:@"2" ofType:@"m4v"];
NSString *thirdVideoPath = [[NSBundle mainBundle]
pathForResource:@"3" ofType:@"m4v"];
AVPlayerItem *firstVideoItem = [AVPlayerItem playerItemWithURL:
[NSURL fileURLWithPath:firstVideoPath]];
AVPlayerItem *secondVideoItem = [AVPlayerItem playerItemWithURL:
[NSURL fileURLWithPath:secondVideoPath]];
AVPlayerItem *thirdVideoItem = [AVPlayerItem playerItemWithURL:
[NSURL fileURLWithPath:thirdVideoPath]];
self.queuePlayer = [AVQueuePlayer queuePlayerWithItems:
[NSArray arrayWithObjects:firstVideoItem,
secondVideoItem,thirdVideoItem,nil]];
[self.playerView setPlayer:self.queuePlayer];
[self.queuePlayer play];