无法在iOS 10及更高版本中正确设置相机闪光灯(这在iOS 9中正常工作)。它总是默认为UIImagePickerControllerCameraFlashModeAuto。
这是我的代码:
UIImagePickerController *picker = [[UIImagePickerController alloc] init];
[picker setAllowsEditing:NO];
[picker setDelegate:self];
[picker setSourceType:UIImagePickerControllerSourceTypeCamera];
[picker setCameraFlashMode:UIImagePickerControllerCameraFlashModeOn];
[picker setCameraOverlayView:overlayView];
[self presentViewController:picker animated:YES completion:Nil];
答案 0 :(得分:2)
所以我想我必须等待渲染UIImagePickerController并再次设置相机闪光灯。
所以我更新了
CREATE INDEX items_geom_idx ON items(geometry)
INDEXTYPE IS MDSYS.SPATIAL_INDEX;
到
[self presentViewController:picker animated:YES completion:nil];
希望这可以提供帮助。