diff options
author | Weijie Wang <weijiew@codeaurora.org> | 2017-07-13 19:54:35 +0800 |
---|---|---|
committer | Weijie Wang <weijiew@codeaurora.org> | 2017-07-13 19:54:35 +0800 |
commit | 5e69aa42e76b43e68bcf6373b6c18fc0e25ea3e0 (patch) | |
tree | 07e21f07fb4613887c352a687e4fc6351f71155b /src/org/codeaurora/snapcam/filter | |
parent | 2b2d7f4c6cffdc6ad6bc0b6ef459271291c99aea (diff) | |
download | android_packages_apps_Snap-5e69aa42e76b43e68bcf6373b6c18fc0e25ea3e0.tar.gz android_packages_apps_Snap-5e69aa42e76b43e68bcf6373b6c18fc0e25ea3e0.tar.bz2 android_packages_apps_Snap-5e69aa42e76b43e68bcf6373b6c18fc0e25ea3e0.zip |
SnapdragonCamera: Add vendor tag util
Check if the tag is available before apply the settings
Change-Id: Ic0242b8aa7711ad230f3aba9e30d5da61d188fe5
Diffstat (limited to 'src/org/codeaurora/snapcam/filter')
-rw-r--r-- | src/org/codeaurora/snapcam/filter/ClearSightImageProcessor.java | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/org/codeaurora/snapcam/filter/ClearSightImageProcessor.java b/src/org/codeaurora/snapcam/filter/ClearSightImageProcessor.java index b2a81389d..feb6693f2 100644 --- a/src/org/codeaurora/snapcam/filter/ClearSightImageProcessor.java +++ b/src/org/codeaurora/snapcam/filter/ClearSightImageProcessor.java @@ -87,7 +87,7 @@ 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.VendorTagUtil; public class ClearSightImageProcessor { private static final String TAG = "ClearSightImageProcessor"; @@ -1082,7 +1082,7 @@ public class ClearSightImageProcessor { private void sendReprocessRequest(CaptureRequest.Builder reprocRequest, Image image, final int camType) { try { - reprocRequest.set(CaptureModule.JpegCropEnableKey, (byte)1); + VendorTagUtil.setJpegCropEnable(reprocRequest, (byte)1); Rect cropRect = image.getCropRect(); if(cropRect == null || @@ -1093,14 +1093,14 @@ public class ClearSightImageProcessor { cropRect = getFinalCropRect(cropRect); // has crop rect. apply to jpeg request - reprocRequest.set(CaptureModule.JpegCropRectKey, + VendorTagUtil.setJpegCropRect(reprocRequest, new int[] {cropRect.left, cropRect.top, cropRect.width(), cropRect.height()}); if(camType == CAM_TYPE_MONO) { - reprocRequest.set(CaptureModule.JpegRoiRectKey, + VendorTagUtil.setJpegRoiRect(reprocRequest, new int[] {0, 0, mFinalMonoSize.getWidth(), mFinalMonoSize.getHeight()}); } else { - reprocRequest.set(CaptureModule.JpegRoiRectKey, + VendorTagUtil.setJpegRoiRect(reprocRequest, new int[] {0, 0, mFinalPictureSize.getWidth(), mFinalPictureSize.getHeight()}); } |