summaryrefslogtreecommitdiffstats
path: root/libcamera
diff options
context:
space:
mode:
authorMike J. Chen <mjchen@sta.samsung.com>2010-10-27 22:22:44 -0700
committerAndroid Git Automerger <android-git-automerger@android.com>2010-10-27 22:22:44 -0700
commitef6a8e465eeb9a059787f897edf86c0f9a3dfb85 (patch)
tree5692c57d958a2e19834496a9bdd4fefd43833deb /libcamera
parenta055a1a90e532d0909bc9a0b9392a2374987129f (diff)
parent88bfb935e7ea2ce06a6021df84bb952eb94432b0 (diff)
downloaddevice_samsung_crespo-ef6a8e465eeb9a059787f897edf86c0f9a3dfb85.zip
device_samsung_crespo-ef6a8e465eeb9a059787f897edf86c0f9a3dfb85.tar.gz
device_samsung_crespo-ef6a8e465eeb9a059787f897edf86c0f9a3dfb85.tar.bz2
am 88bfb935: am efbd4cb5: S5PC11X: libcamera: Fix nightshot mode exception
Diffstat (limited to 'libcamera')
-rw-r--r--libcamera/SecCameraHWInterface.cpp34
1 files changed, 17 insertions, 17 deletions
diff --git a/libcamera/SecCameraHWInterface.cpp b/libcamera/SecCameraHWInterface.cpp
index d2047c1..1c90601 100644
--- a/libcamera/SecCameraHWInterface.cpp
+++ b/libcamera/SecCameraHWInterface.cpp
@@ -1701,6 +1701,23 @@ status_t CameraHardwareSec::setParameters(const CameraParameters& params)
}
}
+ // fps range
+ int new_min_fps = 0;
+ int new_max_fps = 0;
+ int current_min_fps, current_max_fps;
+ params.getPreviewFpsRange(&new_min_fps, &new_max_fps);
+ mParameters.getPreviewFpsRange(&current_min_fps, &current_max_fps);
+ /* our fps range is determined by the sensor, reject any request
+ * that isn't exactly what we're already at.
+ */
+ if ((new_min_fps != current_min_fps) || (new_max_fps != current_max_fps)) {
+ LOGW("%s : requested new_min_fps = %d, new_max_fps = %d not allowed",
+ __func__, new_min_fps, new_max_fps);
+ LOGE("%s : current_min_fps = %d, current_max_fps = %d",
+ __func__, current_min_fps, current_max_fps);
+ ret = UNKNOWN_ERROR;
+ }
+
// scene mode
const char *new_scene_mode_str = params.get(CameraParameters::KEY_SCENE_MODE);
@@ -1847,23 +1864,6 @@ status_t CameraHardwareSec::setParameters(const CameraParameters& params)
// ---------------------------------------------------------------------------
- // fps range
- int new_min_fps = 0;
- int new_max_fps = 0;
- int current_min_fps, current_max_fps;
- params.getPreviewFpsRange(&new_min_fps, &new_max_fps);
- mParameters.getPreviewFpsRange(&current_min_fps, &current_max_fps);
- /* our fps range is determined by the sensor, reject any request
- * that isn't exactly what we're already at.
- */
- if ((new_min_fps != current_min_fps) || (new_max_fps != current_max_fps)) {
- LOGW("%s : requested new_min_fps = %d, new_max_fps = %d not allowed",
- __func__, new_min_fps, new_max_fps);
- LOGE("%s : current_min_fps = %d, current_max_fps = %d",
- __func__, current_min_fps, current_max_fps);
- ret = UNKNOWN_ERROR;
- }
-
// image effect
const char *new_image_effect_str = params.get(CameraParameters::KEY_EFFECT);
if (new_image_effect_str != NULL) {