Skip to content
This repository was archived by the owner on Jun 16, 2023. It is now read-only.

Commit f4965cf

Browse files
committed
feat(ios): check if white balance mode locked is supported
1 parent 8c2100d commit f4965cf

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

ios/RN/RNCamera.m

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -612,9 +612,8 @@ - (void)updateWhiteBalance
612612
return;
613613
}
614614

615-
if (self.whiteBalance == RNCameraWhiteBalanceAuto) {
615+
if (self.whiteBalance == RNCameraWhiteBalanceAuto || ![device isWhiteBalanceModeSupported:AVCaptureWhiteBalanceModeLocked]) {
616616
[device setWhiteBalanceMode:AVCaptureWhiteBalanceModeContinuousAutoWhiteBalance];
617-
[device unlockForConfiguration];
618617
} else {
619618
AVCaptureWhiteBalanceGains rgbGains;
620619
if (self.whiteBalance == RNCameraWhiteBalanceCustom

0 commit comments

Comments
 (0)