Created
August 30, 2020 12:01
-
-
Save agammahajan1/5ff1f9c4de360c6df34e8c5270d9873d to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
let videoURL = URL(string: "Sample-Video-Url") | |
let player = AVPlayer(url: videoURL!) | |
let playerViewController = AVPlayerViewController() | |
playerViewController.player = player | |
self.present(playerViewController, animated: true) { | |
playerViewController.player.play() | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment