diff options
author | xianming wang <mingwax@codeaurora.org> | 2017-12-20 17:35:58 +0800 |
---|---|---|
committer | Gerrit - the friendly Code Review server <code-review@localhost> | 2018-01-24 19:25:42 -0800 |
commit | 9dcf24bef4331a8db1a9ee62f91e00441c52f1c4 (patch) | |
tree | 0184be6236326323df2e32e5ff75d1ee2f7b366c /src/com/android/camera/util | |
parent | 3ca485a0795295871ab5908d0224d636ba23a069 (diff) | |
download | android_packages_apps_Snap-9dcf24bef4331a8db1a9ee62f91e00441c52f1c4.tar.gz android_packages_apps_Snap-9dcf24bef4331a8db1a9ee62f91e00441c52f1c4.tar.bz2 android_packages_apps_Snap-9dcf24bef4331a8db1a9ee62f91e00441c52f1c4.zip |
SnapdragonCamera: Add command to set videoSize
Add setprop "persist.vendor.camera.video.size" to set the video size.
Change-Id: Icd6792a3afc36c11902d839e2981507cb78bd31c
CRs-Fixed: 2175168
Diffstat (limited to 'src/com/android/camera/util')
-rw-r--r-- | src/com/android/camera/util/PersistUtil.java | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/src/com/android/camera/util/PersistUtil.java b/src/com/android/camera/util/PersistUtil.java index 976389ea2..9cb79ba5a 100644 --- a/src/com/android/camera/util/PersistUtil.java +++ b/src/com/android/camera/util/PersistUtil.java @@ -50,6 +50,8 @@ public class PersistUtil { SystemProperties.getInt("persist.vendor.camera.longshot.shotnum", 50); private static final String PERSIST_CAMERA_PREVIEW_SIZE = SystemProperties.get("persist.vendor.camera.preview.size", ""); + private static final String PERSIST_CAMERA_VIDEO_SIZE = + SystemProperties.get("persist.vendor.camera.video.size", ""); private static final boolean PERSIST_CAMERA_CAMERA2 = SystemProperties.getBoolean("persist.vendor.camera.camera2", true); private static final boolean PERSIST_CAMERA_ZSL = @@ -150,6 +152,19 @@ public class PersistUtil { return result; } + public static Point getCameraVideoSize() { + Point result = null; + if (PERSIST_CAMERA_VIDEO_SIZE != null) { + String[] sourceStrArray = PERSIST_CAMERA_VIDEO_SIZE.split("x"); + if (sourceStrArray != null && sourceStrArray.length >= 2) { + result = new Point(); + result.x = Integer.parseInt(sourceStrArray[0]); + result.y = Integer.parseInt(sourceStrArray[1]); + } + } + return result; + } + public static boolean getCamera2Mode() { return PERSIST_CAMERA_CAMERA2; } |