From 4286af343034d16882121c41e659e17c1383463a Mon Sep 17 00:00:00 2001 From: junjiez Date: Tue, 15 Jan 2019 14:08:33 +0800 Subject: SnapdraongCamera:Fix HAL-ZSL flash The capture result of preview repeating request has delay, need to discard the preview capture result when the AE lock is still true after unlock focus to avoid chosing HAL-ZSL when flash is needed. Change-Id: I7b478c11be93fa12fdb4773dc57ec91a2aaf6306 CRs-Fixed: 2372219 --- src/com/android/camera/CaptureModule.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/com/android/camera/CaptureModule.java') diff --git a/src/com/android/camera/CaptureModule.java b/src/com/android/camera/CaptureModule.java index f06521720..843d530bc 100755 --- a/src/com/android/camera/CaptureModule.java +++ b/src/com/android/camera/CaptureModule.java @@ -1898,7 +1898,8 @@ public class CaptureModule implements CameraModule, PhotoController, if ((mSettingsManager.isZSLInHALEnabled() && !isFlashOn(getMainCameraId()) && (mPreviewCaptureResult != null && mPreviewCaptureResult.get(CaptureResult.CONTROL_AE_STATE) != - CameraMetadata.CONTROL_AE_STATE_FLASH_REQUIRED)) || + CameraMetadata.CONTROL_AE_STATE_FLASH_REQUIRED && + mPreviewCaptureResult.getRequest().get(CaptureRequest.CONTROL_AE_LOCK) != Boolean.TRUE)) || isActionImageCapture()) { takeZSLPictureInHAL(); } else { -- cgit v1.2.3