I’m trying to take a full screen image of the camera picture without having the overlay ontop.
In my overlay controller I have tried to hide the overlay with this lines of code:
[self.view setHidden:YES];
[self.view setNeedsDisplay];
CGImageRef screen = UIGetScreenImage();
UIImage* image = [UIImage imageWithCGImage:screen];
CGImageRelease(screen);
self.view.hidden = NO;
UIGetScreenImage still shows the overlay UI.
Is there any way to make this happen?
You’ll need to set the
cameraOverlayViewproperty of theUIImagePickerControllerinstance and then use thetakePicturemethod to get the current image. In your delegate, you need to implement:Apple made UIGetScreenImage() a private API again, so you’re not allowed to use that anymore.