Play video in swift

var moviePlayerController: MPMoviePlayerController?
func playVideo(_ strVideoUrl: URL) {
        print("strVideoUrl: \(strVideoUrl)")
        moviePlayerController = MPMoviePlayerController(contentURL: strVideoUrl)
        moviePlayerController?.view.frame = CGRect.init(x: -10, y: 0, width: SCREEN_WIDTH, height: 200)
        moviePlayerController?.movieSourceType = .streaming
        moviePlayerController?.view.translatesAutoresizingMaskIntoConstraints = true
        viewVedio.addSubview((moviePlayerController?.view)!)
        moviePlayerController?.play()        
}