summaryrefslogtreecommitdiffstats
path: root/src/org/codeaurora/snapcam/filter
diff options
context:
space:
mode:
authorWeijie Wang <weijiew@codeaurora.org>2017-07-21 10:00:45 +0800
committerWeijie Wang <weijiew@codeaurora.org>2017-09-04 18:25:41 +0800
commit278267a43e560e7146ae842e393329501ab7dc9b (patch)
tree3adfce103b44376640d567d33b58a20b9568ac12 /src/org/codeaurora/snapcam/filter
parenta62a89837eac75a9de2404d3bbce76d81d6fd018 (diff)
downloadandroid_packages_apps_Snap-278267a43e560e7146ae842e393329501ab7dc9b.tar.gz
android_packages_apps_Snap-278267a43e560e7146ae842e393329501ab7dc9b.tar.bz2
android_packages_apps_Snap-278267a43e560e7146ae842e393329501ab7dc9b.zip
SnapdragonCamera: Move property to PersistUtil
Move property to PersistUtil Change-Id: I0735d8215ba302ef4c632d6a15ad95a04cd259a0
Diffstat (limited to 'src/org/codeaurora/snapcam/filter')
-rw-r--r--src/org/codeaurora/snapcam/filter/ClearSightImageProcessor.java19
1 files changed, 7 insertions, 12 deletions
diff --git a/src/org/codeaurora/snapcam/filter/ClearSightImageProcessor.java b/src/org/codeaurora/snapcam/filter/ClearSightImageProcessor.java
index 03e06a1a1..8a871aa01 100644
--- a/src/org/codeaurora/snapcam/filter/ClearSightImageProcessor.java
+++ b/src/org/codeaurora/snapcam/filter/ClearSightImageProcessor.java
@@ -87,16 +87,11 @@ import com.android.camera.PhotoModule.NamedImages.NamedEntity;
import com.android.camera.SettingsManager;
import com.android.camera.Storage;
import com.android.camera.util.CameraUtil;
+import com.android.camera.util.PersistUtil;
import com.android.camera.util.VendorTagUtil;
public class ClearSightImageProcessor {
private static final String TAG = "ClearSightImageProcessor";
- private static final String PERSIST_TIMESTAMP_LIMIT_KEY = "persist.vendor.camera.cs.threshold";
- private static final String PERSIST_BURST_COUNT_KEY = "persist.vendor.camera.cs.burstcount";
- private static final String PERSIST_DUMP_FRAMES_KEY = "persist.vendor.camera.cs.dumpframes";
- private static final String PERSIST_DUMP_YUV_KEY = "persist.vendor.camera.cs.dumpyuv";
- private static final String PERSIST_CS_TIMEOUT_KEY = "persist.vendor.camera.cs.timeout";
- private static final String PERSIST_DUMP_DEPTH_KEY = "persist.vendor.camera.cs.dumpdepth";
private static final long DEFAULT_TIMESTAMP_THRESHOLD_MS = 10;
private static final int DEFAULT_IMAGES_TO_BURST = 4;
@@ -172,26 +167,26 @@ public class ClearSightImageProcessor {
private ClearSightImageProcessor() {
mNamedImages = new NamedImages();
- long threshMs = SystemProperties.getLong(PERSIST_TIMESTAMP_LIMIT_KEY, DEFAULT_TIMESTAMP_THRESHOLD_MS);
+ long threshMs = PersistUtil.getTimestampLimit();
mTimestampThresholdNs = threshMs * 1000000;
Log.d(TAG, "mTimestampThresholdNs: " + mTimestampThresholdNs);
- mNumBurstCount = SystemProperties.getInt(PERSIST_BURST_COUNT_KEY, DEFAULT_IMAGES_TO_BURST);
+ mNumBurstCount = PersistUtil.getImageToBurst();
Log.d(TAG, "mNumBurstCount: " + mNumBurstCount);
mNumFrameCount = mNumBurstCount - 1;
Log.d(TAG, "mNumFrameCount: " + mNumFrameCount);
- mDumpImages = SystemProperties.getBoolean(PERSIST_DUMP_FRAMES_KEY, false);
+ mDumpImages = PersistUtil.isDumpFramesEnabled();
Log.d(TAG, "mDumpImages: " + mDumpImages);
- mDumpYUV = SystemProperties.getBoolean(PERSIST_DUMP_YUV_KEY, false);
+ mDumpYUV = PersistUtil.isDumpYUVEnabled();
Log.d(TAG, "mDumpYUV: " + mDumpYUV);
- mDumpDepth = SystemProperties.getBoolean(PERSIST_DUMP_DEPTH_KEY, false);
+ mDumpDepth = PersistUtil.isDumpDepthEnabled();
Log.d(TAG, "mDumpDepth: " + mDumpDepth);
- mCsTimeout = SystemProperties.getInt(PERSIST_CS_TIMEOUT_KEY, DEFAULT_CS_TIMEOUT_MS);
+ mCsTimeout = PersistUtil.getClearSightTimeout();
Log.d(TAG, "mCsTimeout: " + mCsTimeout);
}