diff options
author | Zhijun He <zhijunhe@google.com> | 2014-09-05 21:53:53 +0000 |
---|---|---|
committer | Android (Google) Code Review <android-gerrit@google.com> | 2014-09-05 21:53:53 +0000 |
commit | 3c15d9b12394c62b58ab101c958e354f2c2bea19 (patch) | |
tree | 787162af57d9e98f2d3090fefb2c7e06267e79da /services/camera/libcameraservice/api1 | |
parent | ade312d5c933cff798c3febefabc47b00390ee4a (diff) | |
parent | e8339fb87364469feb1f2cbda92889efecb79a7c (diff) | |
download | frameworks_av-3c15d9b12394c62b58ab101c958e354f2c2bea19.zip frameworks_av-3c15d9b12394c62b58ab101c958e354f2c2bea19.tar.gz frameworks_av-3c15d9b12394c62b58ab101c958e354f2c2bea19.tar.bz2 |
Merge "Camera API1: fix AE state check in precapture state" into lmp-dev
Diffstat (limited to 'services/camera/libcameraservice/api1')
-rw-r--r-- | services/camera/libcameraservice/api1/client2/CaptureSequencer.cpp | 17 |
1 files changed, 12 insertions, 5 deletions
diff --git a/services/camera/libcameraservice/api1/client2/CaptureSequencer.cpp b/services/camera/libcameraservice/api1/client2/CaptureSequencer.cpp index cb9aca6..9849f4d 100644 --- a/services/camera/libcameraservice/api1/client2/CaptureSequencer.cpp +++ b/services/camera/libcameraservice/api1/client2/CaptureSequencer.cpp @@ -445,11 +445,18 @@ CaptureSequencer::CaptureState CaptureSequencer::manageStandardPrecaptureWait( if (mNewAEState) { if (!mAeInPrecapture) { // Waiting to see PRECAPTURE state - if (mAETriggerId == mTriggerId && - mAEState == ANDROID_CONTROL_AE_STATE_PRECAPTURE) { - ALOGV("%s: Got precapture start", __FUNCTION__); - mAeInPrecapture = true; - mTimeoutCount = kMaxTimeoutsForPrecaptureEnd; + if (mAETriggerId == mTriggerId) { + if (mAEState == ANDROID_CONTROL_AE_STATE_PRECAPTURE) { + ALOGV("%s: Got precapture start", __FUNCTION__); + mAeInPrecapture = true; + mTimeoutCount = kMaxTimeoutsForPrecaptureEnd; + } else if (mAEState == ANDROID_CONTROL_AE_STATE_CONVERGED || + mAEState == ANDROID_CONTROL_AE_STATE_FLASH_REQUIRED) { + // It is legal to transit to CONVERGED or FLASH_REQUIRED + // directly after a trigger. + ALOGV("%s: AE is already in good state, start capture", __FUNCTION__); + return STANDARD_CAPTURE; + } } } else { // Waiting to see PRECAPTURE state end |