Skip to content

Commit

Permalink
NA
Browse files Browse the repository at this point in the history
  • Loading branch information
swagatnayak committed Mar 14, 2021
1 parent b46552e commit f1b50ec
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -72,8 +72,9 @@ class SubtitleWithAVPlayerViewController: UIViewController, AVPlayerViewControll
self.playerViewController?.player = player
self.playerViewController?.delegate = self
self.playerViewController?.player?.play()

// MARK: - Enter subtitle url here here (srt or vtt)
self.playerViewController?.addSubtitles().open(fileFromRemote: URL(string: "https://gist.githubusercontent.com/samdutton/ca37f3adaf4e23679957b8083e061177/raw/e19399fbccbc069a2af4266e5120ae6bad62699a/sample.vtt")!)
self.playerViewController?.addSubtitles().open(fileFromRemote: URL(string: "https://raw.githubusercontent.com/swagatnayak/SNAVPlayerSubtitles/master/SNAVPlayerSubtitlesSample")!)

self.present(playerViewController!, animated: true, completion: nil)

Expand Down

0 comments on commit f1b50ec

Please sign in to comment.