UIView+CameraBackground
Show camera layer as a background to any UIView.
Features
- Both front and back camera supported.
- Flash modes: auto, on, off.
- Countdown timer.
- Tap to focus.
- Pinch to zoom.
Usage
Important: Remember to add NSCameraUsageDescription
to your Info.plist
.
Layout
You can change the location of the camera controls (flash, timer, and front/back camera selection) or hide them altogether:
Installation
CocoaPods:
Legacy versions:
Swift version | CameraBackground version |
---|---|
4.0 (Xcode 9.4) | pod 'MiniLayout', '~> 1.2.1' pod 'MultiToggleButton', '~> 1.7.1' pod 'CameraBackground', '~> 1.4.1' |
3 | pod 'MiniLayout', '~> 1.1.0' pod 'MultiToggleButton', '~> 1.5.2' pod 'CameraBackground', '~> 1.2' |
2.3 | pod 'MiniLayout', '~> 1.0.1' pod 'MultiToggleButton', '~> 1.4.0' pod 'CameraBackground', '~> 1.0.2' |
Swift Package Manager:
Meta
https://github.com/yonat/CameraBackground