YoutubeKit
YoutubeKit copied to clipboard
is there any way to change player backgroundColor?
youtubePlayer = YTSwiftyPlayer(
frame: CGRect(x: 0, y: 0, width: postView.frame.size.width, height: postView.frame.size.height),
playerVars: [
.playsInline(true),
.videoID(videoUrl.getVideoIDFromYoutubeUrl()),
.loopVideo(false),
.showRelatedVideo(false)
])
youtubePlayer?.autoplay = true
youtubePlayer?.backgroundColor = Color.videoBackground.value
self.postView.addSubview(youtubePlayer ?? YTSwiftyPlayer())
//youtubePlayer?.delegate = self
youtubePlayer?.loadPlayer()
and i also want to know to hide morevideos when the video is stopped
thanks