因此,我正在尝试更新适用于 iOS 7 的应用程序,但我的自定义叠加层遇到了问题。叠加层是我用来构图的图像(实时和使用全分辨率版本在相机胶卷中构图最终结果)。问题是现在,在 iOS 7 下,覆盖层虽然在底部是透明的,但提供了对常规“拍照”按钮的访问,但由于某种原因不会让我点击“使用照片”或“重拍”按钮拍照后出现。这是调用视图控制器的代码片段:
- (IBAction)takePhoto:(UIButton *)sender {
UIImagePickerController *picker = [[UIImagePickerController alloc] init];
picker.delegate = self;
picker.allowsEditing = NO;
picker.sourceType = UIImagePickerControllerSourceTypeCamera;
picker.showsCameraControls = YES;
// Overlay Creation
UIView* overlayView = [[UIView alloc] initWithFrame:picker.view.frame];
overlayView.backgroundColor = [UIColor colorWithPatternImage:[UIImage imageNamed:@"PBOverlayView.png"]];
[overlayView.layer setOpaque:NO];
overlayView.opaque = NO;
picker.cameraOverlayView = overlayView;
[self presentViewController:picker animated:YES completion:NULL];
}