summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSultanxda <sultanxda@gmail.com>2015-08-21 03:06:08 (GMT)
committerGerrit Code Review <gerrit@cyanogenmod.org>2016-01-08 17:14:27 (GMT)
commitfc08f9e6eb08a11d029ed9f2fbdb3cb7359af1cc (patch)
tree5adec77f46bc61c70345e344eea31f44930e563a
parent6d5c4d042bedef2a934fb4c0d1ae149e94405178 (diff)
downloadandroid_packages_apps_Snap-fc08f9e6eb08a11d029ed9f2fbdb3cb7359af1cc.zip
android_packages_apps_Snap-fc08f9e6eb08a11d029ed9f2fbdb3cb7359af1cc.tar.gz
android_packages_apps_Snap-fc08f9e6eb08a11d029ed9f2fbdb3cb7359af1cc.tar.bz2
SnapdragonCamera: Fix incorrect viewfinder ratio for 13.1MP shots
Set the aspect tolerance to 0.02 to compensate for 13.1MP (4208x3120) shots. 13.1MP will now be properly registered as a 4/3 resolution when the viewfinder ratio is calculated. Change-Id: I41540a0d5fbe11f59d776a6e70e82baa463fff59
-rw-r--r--src/com/android/camera/util/CameraUtil.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/com/android/camera/util/CameraUtil.java b/src/com/android/camera/util/CameraUtil.java
index 893f8a7..9d851e8 100644
--- a/src/com/android/camera/util/CameraUtil.java
+++ b/src/com/android/camera/util/CameraUtil.java
@@ -534,7 +534,7 @@ public class CameraUtil {
public static int getOptimalPreviewSize(Activity currentActivity,
Point[] sizes, double targetRatio) {
// Use a very small tolerance because we want an exact match.
- final double ASPECT_TOLERANCE = 0.01;
+ final double ASPECT_TOLERANCE = 0.02;
if (sizes == null) return -1;
int optimalSizeIndex = -1;