summaryrefslogtreecommitdiffstats
path: root/src_wrapper
diff options
context:
space:
mode:
authorVijay kumar Tumati <vtumati@codeaurora.org>2015-04-13 15:36:33 +0530
committerChippa-a <vusal1372@gmail.com>2019-10-25 15:55:25 +0300
commit3c6be8ace369c76a16c58863da1786ba1afe90ba (patch)
treefecedf9ebfcfeda59a5df0c0417be0d06aeb9d60 /src_wrapper
parentebb7595d804a5ab8e1014f415fd086dc3d41d3a0 (diff)
downloadandroid_packages_apps_Snap-3c6be8ace369c76a16c58863da1786ba1afe90ba.tar.gz
android_packages_apps_Snap-3c6be8ace369c76a16c58863da1786ba1afe90ba.tar.bz2
android_packages_apps_Snap-3c6be8ace369c76a16c58863da1786ba1afe90ba.zip
SnapdragonCamera: Longshot with Burst Functionality.
This is a new Longshot feature where in the snapshot frames captured at ISP is @ 3fps and output JPEG encoded rate is @ 1.2 fps. This can be enabled by setting following setprop with the maximum number of snapshots. adb shell setprop persist.camera.longshot.max <max_number> e.g.:adb shell setprop persist.camera.longshot.max 10 If the number is -1, then the existing Longshot will be used. Main changes: 1) The number of Snapshot/Preview/Metadata buffers are increased to make sure no frames will be dropped @ ISP and to maintain burst fps. e.g.: For max number of 10 snapshots, Snapshot buffers are increased to 9 from existing 6. This buffer numbers are derived considering snapshot YUV frames @ 3 fps and JPEG encoding @ 1.2 fps. 2) Shutter will be played after receiving YUV frame instead of reprocess frame. 3) New Longshot stop command is sent after receiving all the required YUV callbacks or releasing the shutter before reaching Max number. 4) Existing Longshot off command is sent after receiving all JPEG CB.s for the issued TakePictures() and also shutter button will be disabled until all the JPEG callbacks are received. Change-Id: Id0c21aeb67245530768bf3ab859d39dea7e2bc40
Diffstat (limited to 'src_wrapper')
-rw-r--r--src_wrapper/org/codeaurora/snapcam/wrapper/CameraWrapper.java17
1 files changed, 17 insertions, 0 deletions
diff --git a/src_wrapper/org/codeaurora/snapcam/wrapper/CameraWrapper.java b/src_wrapper/org/codeaurora/snapcam/wrapper/CameraWrapper.java
index 6739686e9..bbde33af2 100644
--- a/src_wrapper/org/codeaurora/snapcam/wrapper/CameraWrapper.java
+++ b/src_wrapper/org/codeaurora/snapcam/wrapper/CameraWrapper.java
@@ -119,4 +119,21 @@ public class CameraWrapper extends Wrapper{
}
}
+ private static Method method_stopLongshot = null;
+ public static final void stopLongshot(Camera camera){
+ if ( DEBUG ){
+ Log.e(TAG, "" + Camera.class + " no stopLongshot");
+ return;
+ }
+ try {
+ if (method_stopLongshot == null) {
+ method_stopLongshot =
+ Camera.class.getDeclaredMethod("stopLongshot");
+ }
+ method_stopLongshot.invoke(camera);
+ }catch (Exception exception){
+ exception.printStackTrace();
+ }
+ }
+
}