I use an UIImagePickerController
to show rear camera as background.
Everything works as expected, but in iPhone 5
and maybe in iPhone 4s
I have a green box in the image like
I think is a face detection feature, but I don't now how to disable it. Any suggestion?
This is a code snippet that I use for UIImagePickerController
:
I declare ad UIView in my .h file
UIView *overlay;
And in the init method of my .m file
#define CAMERA_TRANSFORM 1.24299
UIImagePickerController *uip;
@try {
uip = [[[UIImagePickerController alloc] init] autorelease];
uip.sourceType = UIImagePickerControllerSourceTypeCamera;
uip.showsCameraControls = NO;
uip.toolbarHidden = YES;
uip.navigationBarHidden = YES;
uip.wantsFullScreenLayout = YES;
uip.cameraViewTransform = CGAffineTransformScale(uip.cameraViewTransform, CAMERA_TRANSFORM, CAMERA_TRANSFORM);
}
@catch (NSException * e) {
[uip release];
uip = nil;
}
@finally {
if(uip) {
[overlay addSubview:[uip view]];
[overlay release];
}
}