xeieshan / ZHMaskCamera

ZHMaskCamera is a camera that takes UIImage (masking image), takes a photo but it gives you a masked picture from captured photo.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

ZHMaskCamera

It will show overlay as per masked image in camera preview, When You capture image, it show the overlay as is and it returns u a masked image removing the part you didn’t want to capture.

Works with iPad, iPhoneX, iPhone 8Plus, iPhone 8, iPhone SE Works with latest iOS and Xcode

This app requires to access your camera to capture image with mask layer and then afterwards masks image.

Assign maskingImage in ZHCameraViewController.swift class.

override func viewDidLoad() {
        super.viewDidLoad()
        self.maskingImage = #imageLiteral(resourceName: "Xbox360Mask.png")
        // Image Xbox360Mask.png is added in assets
        setupView()
}

The maskingImage I am using is this : Masking Image Xbox Controller So you can see the results below using just masking image I can capture a masked image

Screenshots

Splash screen

Splash screen

Camera layer

Camera

While capturing try to center the object in mask

Capturing

Masked image after capturing

Masked after capturing

Feel free to use

About

ZHMaskCamera is a camera that takes UIImage (masking image), takes a photo but it gives you a masked picture from captured photo.

License:MIT License


Languages

Language:Swift 100.0%