Advertise here

Advertise here

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Rendering camera view into an image

AshtashooterAshtashooter MalaysiaPosts: 25New Users @
I'm trying to take a screenshot of a partially transparent UIImage along with the camera view behind it. Specifically, I want the part of the camera view that shows through the image to be included in the captured image. It's like cropping part of the camera view according to the size and location of the image on top of it. How am I gonna be able to achieve that?

Here is the code that I'm using:
        UIGraphicsBeginImageContextWithOptions(self.camView.bounds.size, false, 0)
        var image:UIImage = UIGraphicsGetImageFromCurrentImageContext()
        UIImageWriteToSavedPhotosAlbum(image, nil, nil, nil)

Thank you
Sign In or Register to comment.