diff options
author | codeworkx <daniel.hillenbrand@codeworkx.de> | 2019-03-03 18:13:21 +0100 |
---|---|---|
committer | Rashed Abdel-Tawab <rashedabdeltawab@gmail.com> | 2019-06-15 08:47:30 +0200 |
commit | ceb4b7412a4f3db92e7d1b4e14c2e76319d1e3f5 (patch) | |
tree | f4ed7d37ab4cccfc38295f55891082a68b9071d9 | |
parent | f8158606a471f40356db7f47c9b3d8a156302d83 (diff) | |
download | android_packages_apps_Snap-ceb4b7412a4f3db92e7d1b4e14c2e76319d1e3f5.tar.gz android_packages_apps_Snap-ceb4b7412a4f3db92e7d1b4e14c2e76319d1e3f5.tar.bz2 android_packages_apps_Snap-ceb4b7412a4f3db92e7d1b4e14c2e76319d1e3f5.zip |
Snap: allow to disable image stabilization per device
Change-Id: I4317f84285bdf97ba321ad5ddba7453f2b5d3b0c
-rw-r--r-- | res/values/config.xml | 3 | ||||
-rwxr-xr-x | src/com/android/camera/CameraSettings.java | 6 |
2 files changed, 9 insertions, 0 deletions
diff --git a/res/values/config.xml b/res/values/config.xml index 342105349..cb78e532c 100644 --- a/res/values/config.xml +++ b/res/values/config.xml @@ -74,6 +74,9 @@ <!-- Minimum picture size (in pixel) to include in selection list --> <integer name="minimum_picture_size">900000</integer> + <!-- Enable support for image stabilization --> + <bool name="support_dis">true</bool> + <!-- Enable support for bokeh mode --> <bool name="support_bokeh_mode">false</bool> </resources> diff --git a/src/com/android/camera/CameraSettings.java b/src/com/android/camera/CameraSettings.java index ab4b1a6a4..107777eba 100755 --- a/src/com/android/camera/CameraSettings.java +++ b/src/com/android/camera/CameraSettings.java @@ -301,6 +301,7 @@ public class CameraSettings { public static String mKeyIso = null; public static String mKeyIsoValues = null; + private static boolean mSupportDis = false; private static boolean mSupportBokehMode = false; private static final HashMap<Integer, String> @@ -473,6 +474,9 @@ public class CameraSettings { Log.d(TAG, "Using key for iso-values: " + mKeyIsoValues); } + // Image stabilization + mSupportDis = mContext.getResources().getBoolean(R.bool.support_dis); + // Bokeh mode mSupportBokehMode = mContext.getResources().getBoolean(R.bool.support_bokeh_mode); } @@ -613,6 +617,8 @@ public class CameraSettings { } public static List<String> getSupportedDISModes(Parameters params) { + if (!mSupportDis) + return null; String str = params.get(KEY_QC_SUPPORTED_DIS_MODES); if (str == null) { return null; |