diff options
author | Eino-Ville Talvala <etalvala@google.com> | 2013-10-04 14:39:58 -0700 |
---|---|---|
committer | Eino-Ville Talvala <etalvala@google.com> | 2013-10-04 14:39:58 -0700 |
commit | 51ca8d6bc031313e5040c716cc207c8f62a68891 (patch) | |
tree | e50797e6ba0bd82551a587dbfe6a104ca8ef2f25 /core | |
parent | 5c126892ec53772d784fcf9cef9165acf1d92ce3 (diff) | |
download | frameworks_base-51ca8d6bc031313e5040c716cc207c8f62a68891.zip frameworks_base-51ca8d6bc031313e5040c716cc207c8f62a68891.tar.gz frameworks_base-51ca8d6bc031313e5040c716cc207c8f62a68891.tar.bz2 |
Camera2: Verbosity is verboten.
Bug: 10360518
Change-Id: I155effad61099535bee77cc0d0e380420d96770d
Diffstat (limited to 'core')
-rw-r--r-- | core/java/android/hardware/camera2/impl/CameraMetadataNative.java | 22 |
1 files changed, 15 insertions, 7 deletions
diff --git a/core/java/android/hardware/camera2/impl/CameraMetadataNative.java b/core/java/android/hardware/camera2/impl/CameraMetadataNative.java index 6d04bf8..38e946d 100644 --- a/core/java/android/hardware/camera2/impl/CameraMetadataNative.java +++ b/core/java/android/hardware/camera2/impl/CameraMetadataNative.java @@ -35,6 +35,7 @@ import java.util.HashMap; public class CameraMetadataNative extends CameraMetadata implements Parcelable { private static final String TAG = "CameraMetadataJV"; + private final boolean VERBOSE = Log.isLoggable(TAG, Log.VERBOSE); public CameraMetadataNative() { super(); @@ -400,11 +401,13 @@ public class CameraMetadataNative extends CameraMetadata implements Parcelable { int remaining = buffer.remaining(); int arraySize = remaining / elementSize; - Log.v(TAG, - String.format( + if (VERBOSE) { + Log.v(TAG, + String.format( "Attempting to unpack array (count = %d, element size = %d, bytes " + - "remaining = %d) for type %s", + "remaining = %d) for type %s", arraySize, elementSize, remaining, type)); + } array = Array.newInstance(componentType, arraySize); for (int i = 0; i < arraySize; ++i) { @@ -565,8 +568,9 @@ public class CameraMetadataNative extends CameraMetadata implements Parcelable { "Expected values array to be the same size as the enumTypes values " + values.length + " for type " + enumType); } - - Log.v(TAG, "Registered enum values for type " + enumType + " values"); + if (VERBOSE) { + Log.v(TAG, "Registered enum values for type " + enumType + " values"); + } sEnumValues.put(enumType, values); } @@ -654,14 +658,18 @@ public class CameraMetadataNative extends CameraMetadata implements Parcelable { static { nativeClassInit(); - Log.v(TAG, "Shall register metadata marshalers"); + if (VERBOSE) { + Log.v(TAG, "Shall register metadata marshalers"); + } // load built-in marshallers registerMarshaler(new MetadataMarshalRect()); registerMarshaler(new MetadataMarshalSize()); registerMarshaler(new MetadataMarshalString()); - Log.v(TAG, "Registered metadata marshalers"); + if (VERBOSE) { + Log.v(TAG, "Registered metadata marshalers"); + } } } |