https://github.com/coder-acjhp/uicvideoplayerview
Video player with play, pause, forward, rewind, seek, mute functionalities for IOS
https://github.com/coder-acjhp/uicvideoplayerview
avplayer avplayeritem custom-view ios-swift swift video-player video-stream
Last synced: 6 months ago
JSON representation
Video player with play, pause, forward, rewind, seek, mute functionalities for IOS
- Host: GitHub
- URL: https://github.com/coder-acjhp/uicvideoplayerview
- Owner: Coder-ACJHP
- License: mit
- Created: 2019-04-07T03:08:30.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2019-04-10T15:02:40.000Z (over 6 years ago)
- Last Synced: 2025-03-27T14:11:06.794Z (7 months ago)
- Topics: avplayer, avplayeritem, custom-view, ios-swift, swift, video-player, video-stream
- Language: Swift
- Size: 44.7 MB
- Stars: 6
- Watchers: 2
- Forks: 1
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# UICVideoPlayerView
Video player with play, pause, forward, rewind, seek, mute functionalities for IOS## Screen shot (.gif)
## How to use?
1 - Download `UICVideoPlayerView.swift` file (inside UICVideoPlayer folder) with it's assets (inside Assets.xcassets folder) and import it into your project. (Single .swift file and assests "icons")
2 - Allow your application to support arbitrary loads from `info.plist`to allow `http` requests
3 - Setup `UICVideoPlayerView` and add it to your view### Code exmple:
```
private var videoPlayer: UICVideoPlayerView!let calculatedHeight = self.view.frame.width * 9 / 16
let videoLayerFrame = CGRect(x: 0, y: 0, width: self.view.frame.width, height: calculatedHeight)
videoPlayer = UICVideoPlayerView(frame: videoLayerFrame)
videoPlayer.videoLink = sampleVideoLink
videoPlayer.delegate = self
view.addSubview(videoPlayer)// Delegate method :
func dismiss(_ videoView: UICVideoPlayerView) {
// Dismiss videoPlayer view here or what ever you want
}
```
Note: For more information browse example project (DummyViewController)No need to any other thing, so it's features like :
- When the video fail to load it shows error message.
- It shows streaming progress
- When video load will start to play.
- Shows replay button when video finished and resets slider.
- When changing video link it will prepare and update itself immediatly.
- Shows loading spinner depended on buffer status.
- You can share video link to social media and other chanels (new).
- You can change settings from settings context menu (new).
###### Note: This project is sample so only "dismiss & cancel" option is working in menu others not!### Requirements
Xcode 9 or later
iOS 10.0 or later
Swift 4 or later### Next update will add :
1 - Support play list of videos.
2 - Next and previous buttons.
3 - Support landscape mode.### Licence :
The MIT License (MIT)