summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDheeraj CVR <cvr.dheeraj@gmail.com>2014-01-11 15:35:45 +0530
committersbrissen <sbrissen@hotmail.com>2014-05-01 08:35:39 -0400
commitb6f26b5e415112fd5253a3eee52b996fc918380e (patch)
tree8da8b07676e41ccfc36834c94ff2fde80fc2287f
parent7f06e631b725d7324e8cc794db5597a708e76e08 (diff)
downloaddevice_samsung_smdk4412-common-b6f26b5e415112fd5253a3eee52b996fc918380e.zip
device_samsung_smdk4412-common-b6f26b5e415112fd5253a3eee52b996fc918380e.tar.gz
device_samsung_smdk4412-common-b6f26b5e415112fd5253a3eee52b996fc918380e.tar.bz2
Revert "camera: Fix loss of focus mode between shots"
This reverts commit 40279ba1fd2d4f02d889699df1eccf3d3a01df55. V4L2_CID_CAMERA_FOCUS_MODE has the side effect of resetting the sensor AF position. Hence, the focus is lost each time SetParameters is called and this happens during a snapshot resulting in out of focus pictures. Change-Id: Ia644b62e3752196c0637053150af7899155d6a47
-rw-r--r--camera/exynos_camera.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/camera/exynos_camera.c b/camera/exynos_camera.c
index 7e551dc..6ef2dc6 100644
--- a/camera/exynos_camera.c
+++ b/camera/exynos_camera.c
@@ -1086,9 +1086,11 @@ int exynos_camera_params_apply(struct exynos_camera *exynos_camera, int force)
}
}
- rc = exynos_v4l2_s_ctrl(exynos_camera, 0, V4L2_CID_CAMERA_FOCUS_MODE, focus_mode);
- if (rc < 0)
- ALOGE("%s: Unable to set focus mode", __func__);
+ if (focus_mode != exynos_camera->focus_mode || force) {
+ rc = exynos_v4l2_s_ctrl(exynos_camera, 0, V4L2_CID_CAMERA_FOCUS_MODE, focus_mode);
+ if (rc < 0)
+ ALOGE("%s: Unable to set focus mode", __func__);
+ }
exynos_camera->focus_mode = focus_mode;
sprintf(exynos_camera->raw_focus_mode, "%s", focus_mode_string);