Swiftpack.co - Package - weitieda/Lupi

Lupi

Platform Swift MIT License

One-line configuration video background for iOS project, written in Swift.

preview preview

Features

  • [x] One line of code to make it work
  • [x] Handled device rotation by default

Usage

import Lupi

class ViewController: UIViewController {

    var videoBackgrounView: LupiVideoBackgroundView?

    override func viewDidLoad() {
        super.viewDidLoad()

        videoBackgrounView = try? LupiVideoBackgroundView(fileName: "beach", in: view)
    }
}

By default, audio is muted. Pass isMuted: false in initializer if you want to turn it on.

Installation

CocoaPods

Lupi is available through CocoaPods. To install it, simply add the following line to your Podfile:

pod 'Lupi', :git => 'https://github.com/weitieda/Lupi.git'

Swift Package Manager (Xcode 11+)

In Xcode 11, select File -> Swift Packages -> Add Package Dependency, enter Lupi's repo URL https://github.com/weitieda/Lupi. Or you can login Xcode with your GitHub account and just type Lupi to search.

Author

Tieda Wei

License

Lupi is released under an MIT License. See LICENSE for details.

Github

link
Stars: 0

Dependencies

Used By

Total: 0

Releases

1.0.1 - 2020-02-19 02:08:35

  • used weak var for parentView to prevent retain cycle
  • implicitly unwrap playerLayer

1.0.0 - 2020-02-09 15:31:00

First community release