Ensure custom exposure mode is supported
This commit is contained in:
parent
58714f9dac
commit
0faaf5d74c
@ -198,8 +198,12 @@ extension CameraSession {
|
|||||||
guard let captureDevice = AVCaptureDevice.default(for: .video) else {
|
guard let captureDevice = AVCaptureDevice.default(for: .video) else {
|
||||||
print("No capture device available")
|
print("No capture device available")
|
||||||
return
|
return
|
||||||
}
|
|
||||||
|
|
||||||
|
}
|
||||||
|
guard captureDevice.isExposureModeSupported(.custom) else {
|
||||||
|
ReactLogger.log(level: .info, message: "Custom exposure mode not supported")
|
||||||
|
return
|
||||||
|
}
|
||||||
do {
|
do {
|
||||||
// Lock the device for configuration
|
// Lock the device for configuration
|
||||||
try captureDevice.lockForConfiguration()
|
try captureDevice.lockForConfiguration()
|
||||||
|
Loading…
Reference in New Issue
Block a user