About this project

Player is an MIT-licensed iOS and tvOS library written in Swift for adding media playback to an app. It supports local media files and remote HTTP streams, and can also accept AVURLAsset or AVPlayerItem instances for more advanced sources, including custom HTTP headers and iCloud Photos/PHAsset videos. The library is distributed as a child view controller that developers add to their own view hierarchy. Its API exposes a URL, asset, or player item, along with play-from-beginning, pause, fill-mode, current-time, duration, and looping-related behavior. Delegate methods notify the app about playback lifecycle events, time changes, looping, and playback completion, which can be used to build custom progress UI. Documented features include customizable UI and user interaction, support for interface-orientation changes, video fill-mode adjustment, and video-frame snapshots. The repository includes integration examples and API documentation, and installation is supported through Swift Package Manager, CocoaPods, or by copying the single Player.swift source file into an Xcode project. Swift 5.0 is the current supported version, with older branches mentioned for Swift 4.2 and 4.0.