Tutorial by Examples

Objective-C NSURL *url = [[NSURL alloc] initWithString:@"YOUR URL"]; // url can be remote or local AVPlayer *player = [AVPlayer playerWithURL:url]; // create a player view controller AVPlayerViewController *controller = [[AVPlayerViewController alloc] init]; [self presentViewC...
Objective C NSURL *url = [NSURL URLWithString:@"YOUR URL"]; AVPlayer *player = [AVPlayer playerWithURL:videoURL]; AVPlayerLayer *playerLayer = [AVPlayerLayer playerLayerWithPlayer:player]; playerLayer.frame = self.view.bounds; [self.view.layer addSublayer:playerLayer]; [player play];...
AVPlayer *avPlayer = [AVPlayer playerWithURL:[NSURL URLWithString:@"YOUR URL"]]; AVPlayerViewController *avPlayerCtrl = [[AVPlayerViewController alloc] init]; avPlayerCtrl.view.frame = self.view.frame; avPlayerCtrl.player = avPlayer; avPlayerCtrl.delegate = self; [...

Page 1 of 1