Open bogdanpralea opened 4 years ago
please provide some help here. I fetched a VIMVideo object using VimeoNetworking, and used uri variable of the object to create an avasset. But that doesnt plays the video either
Has anyone figured it out?
let videoRequest = Request<VIMVideo>(path: "/videos/419068453")
let _ = VimeoClient.defaultClient.request(videoRequest) { result in
switch result {
case .success(let response):
let video: VIMVideo = response.model
if let file = video.files?.last as? VIMVideoFile {
let player = AVPlayer(url: URL(string: file.link!)!)
let vc = AVPlayerViewController()
vc.player = player
self.present(vc, animated: true) {
vc.player?.play()
}
}
case .failure(let error):
print("error retrieving video: \(error)")
}
}
i figure you require a paid account even for testing.
How do you play a video after getting the videos using VimeoNetworking?
Thanks!