From fecfc168ab1330c4076e1a4576ec0905afdff6a7 Mon Sep 17 00:00:00 2001 From: Dheeraj CVR Date: Sun, 29 Dec 2013 13:41:48 +0530 Subject: smdk4412-common: camera: don't defer picture if CAF is in progress CAF is considerably slower than Auto or Touch Focus and since we are deferring the picture while CAF is in progress, there are delays while taking the picture and these delays are sometimes huge. Disregard the CAF state since we could Touch to Focus if required. Change-Id: If981f6402cc97e0781060dc48fa7d8e44288168f --- camera/exynos_camera.c | 17 +++++------------ 1 file changed, 5 insertions(+), 12 deletions(-) (limited to 'camera/exynos_camera.c') diff --git a/camera/exynos_camera.c b/camera/exynos_camera.c index 7cea71a..8d6f109 100644 --- a/camera/exynos_camera.c +++ b/camera/exynos_camera.c @@ -1532,14 +1532,11 @@ int exynos_camera_capture(struct exynos_camera *exynos_camera) current_af = CAMERA_AF_STATUS_RESTART; } - if (current_af != exynos_camera->auto_focus_result) { - exynos_camera->auto_focus_result = current_af; - if (exynos_camera->auto_focus_enabled) { - rc = exynos_camera_auto_focus(exynos_camera, current_af); - if (rc < 0) { - ALOGE("%s: Unable to auto focus", __func__); - goto error; - } + if (exynos_camera->auto_focus_enabled) { + rc = exynos_camera_auto_focus(exynos_camera, current_af); + if (rc < 0) { + ALOGE("%s: Unable to auto focus", __func__); + goto error; } } @@ -2778,10 +2775,6 @@ int exynos_camera_picture_callback(struct exynos_camera *exynos_camera, pthread_mutex_lock(&exynos_camera->picture_mutex); if (!exynos_camera->picture_enabled && !exynos_camera->camera_fimc_is) { - if (exynos_camera->auto_focus_result == CAMERA_AF_STATUS_IN_PROGRESS) { - pthread_mutex_unlock(&exynos_camera->picture_mutex); - return 0; - } rc = exynos_v4l2_s_ctrl(exynos_camera, 0, V4L2_CID_CAMERA_CAPTURE, 0); if (rc < 0) { -- cgit v1.2.3