diff options
author | Android Build Coastguard Worker <android-build-coastguard-worker@google.com> | 2023-01-10 00:23:23 +0000 |
---|---|---|
committer | Android Build Coastguard Worker <android-build-coastguard-worker@google.com> | 2023-01-10 00:23:23 +0000 |
commit | c3193fe9b7bbd1b4917a01bd2d63c66737234f5c (patch) | |
tree | 76deacea63facb76c0890694b61613659375f87b | |
parent | ba2bbfb04ca7fba485842c1311fa4867694555eb (diff) | |
parent | d7fb362d8c3e51c57f0c9dc2934cb49b0f559b91 (diff) | |
download | Camera2-android13-qpr3-s12-release.tar.gz |
Snap for 9470583 from d7fb362d8c3e51c57f0c9dc2934cb49b0f559b91 to tm-qpr3-releaseandroid-13.0.0_r83android-13.0.0_r79android-13.0.0_r78android-13.0.0_r77android-13.0.0_r76android-13.0.0_r75android-13.0.0_r71android-13.0.0_r70android-13.0.0_r69android-13.0.0_r68android-13.0.0_r67android-13.0.0_r63android-13.0.0_r62android-13.0.0_r61android-13.0.0_r56android-13.0.0_r54android-13.0.0_r53android-13.0.0_r52android-13.0.0_r51android-13.0.0_r50android13-qpr3-s9-releaseandroid13-qpr3-s8-releaseandroid13-qpr3-s7-releaseandroid13-qpr3-s6-releaseandroid13-qpr3-s5-releaseandroid13-qpr3-s4-releaseandroid13-qpr3-s3-releaseandroid13-qpr3-s2-releaseandroid13-qpr3-s14-releaseandroid13-qpr3-s13-releaseandroid13-qpr3-s12-releaseandroid13-qpr3-s11-releaseandroid13-qpr3-s10-releaseandroid13-qpr3-s1-releaseandroid13-qpr3-release
Change-Id: If80e8c089525b6c44bd99db20015c0051c6419dd
-rw-r--r-- | Android.bp | 2 | ||||
-rw-r--r-- | src/com/android/camera/debug/DebugPropertyHelper.java | 8 | ||||
-rw-r--r-- | src/com/android/camera/util/ExifUtil.java | 10 |
3 files changed, 16 insertions, 4 deletions
diff --git a/Android.bp b/Android.bp index a3cad5888..5cf37d569 100644 --- a/Android.bp +++ b/Android.bp @@ -44,7 +44,7 @@ android_app { "20002000", ], - sdk_version: "current", + sdk_version: "system_current", product_specific: true, diff --git a/src/com/android/camera/debug/DebugPropertyHelper.java b/src/com/android/camera/debug/DebugPropertyHelper.java index 66ccaafee..85c0955df 100644 --- a/src/com/android/camera/debug/DebugPropertyHelper.java +++ b/src/com/android/camera/debug/DebugPropertyHelper.java @@ -16,7 +16,7 @@ package com.android.camera.debug; -import com.android.camera.util.SystemProperties; +import android.os.SystemProperties; public class DebugPropertyHelper { private static final String OFF_VALUE = "0"; @@ -38,6 +38,8 @@ public class DebugPropertyHelper { private static final String PROP_WRITE_CAPTURE_DATA = PREFIX + ".capture_write"; /** Is RAW support enabled. */ private static final String PROP_CAPTURE_DNG = PREFIX + ".capture_dng"; + /** Redacting EXIF manufacturer and model name. */ + private static final String PROP_REDACT_EXIF = PREFIX + ".redact_exif"; private static boolean isPropertyOn(String property) { return ON_VALUE.equals(SystemProperties.get(property, OFF_VALUE)); @@ -58,4 +60,8 @@ public class DebugPropertyHelper { public static boolean isCaptureDngEnabled() { return isPropertyOn(PROP_CAPTURE_DNG); } + + public static boolean isRedactExifEnabled() { + return isPropertyOn(PROP_REDACT_EXIF); + } } diff --git a/src/com/android/camera/util/ExifUtil.java b/src/com/android/camera/util/ExifUtil.java index 18150a0c8..5fae24984 100644 --- a/src/com/android/camera/util/ExifUtil.java +++ b/src/com/android/camera/util/ExifUtil.java @@ -20,6 +20,7 @@ import android.hardware.camera2.CaptureResult; import android.location.Location; import android.os.Build; +import com.android.camera.debug.DebugPropertyHelper; import com.android.camera.exif.ExifInterface; import com.android.camera.exif.Rational; import com.android.camera.one.v2.camera2proxy.CaptureResultProxy; @@ -113,8 +114,13 @@ public class ExifUtil { } private void addMakeAndModelToExif() { - addExifTag(ExifInterface.TAG_MAKE, Build.MANUFACTURER); - addExifTag(ExifInterface.TAG_MODEL, Build.MODEL); + if (DebugPropertyHelper.isRedactExifEnabled()) { + addExifTag(ExifInterface.TAG_MAKE, "CAM_YY"); + addExifTag(ExifInterface.TAG_MODEL, "CAM_XX"); + } else { + addExifTag(ExifInterface.TAG_MAKE, Build.MANUFACTURER); + addExifTag(ExifInterface.TAG_MODEL, Build.MODEL); + } } private void addImageDataToExif(TaskImageContainer.TaskImage image) { |