From 855bae407d61b5cc6629248e7692927b4dacd92f Mon Sep 17 00:00:00 2001 From: Ruben Brunk Date: Fri, 17 Jan 2014 10:30:32 -0800 Subject: [PATCH] camera3: Update filterdensity tags. Change-Id: I4e73dcbcfb5a9230e8e2d187e47bc0f829ffc7f6 --- .../hardware/camera2/CameraCharacteristics.java | 14 ++++++++------ core/java/android/hardware/camera2/CaptureRequest.java | 18 ++++++++++++++---- core/java/android/hardware/camera2/CaptureResult.java | 18 ++++++++++++++---- 3 files changed, 36 insertions(+), 14 deletions(-) diff --git a/core/java/android/hardware/camera2/CameraCharacteristics.java b/core/java/android/hardware/camera2/CameraCharacteristics.java index ce0041b5a103..cde9740fe56d 100644 --- a/core/java/android/hardware/camera2/CameraCharacteristics.java +++ b/core/java/android/hardware/camera2/CameraCharacteristics.java @@ -284,12 +284,14 @@ public final class CameraCharacteristics extends CameraMetadata { new Key("android.lens.info.availableApertures", float[].class); /** - *

List of supported ND filter - * values

- *

If not available, only setting is 0. Otherwise, - * lists the available exposure index values for dimming - * (2 would mean the filter is set to reduce incoming - * light by two stops)

+ *

List of supported neutral density filter values for + * {@link CaptureRequest#LENS_FILTER_DENSITY android.lens.filterDensity}.

+ *

If changing {@link CaptureRequest#LENS_FILTER_DENSITY android.lens.filterDensity} is not supported, + * availableFilterDensities must contain only 0. Otherwise, this + * list contains only the exact filter density values available on + * this camera device.

+ * + * @see CaptureRequest#LENS_FILTER_DENSITY */ public static final Key LENS_INFO_AVAILABLE_FILTER_DENSITIES = new Key("android.lens.info.availableFilterDensities", float[].class); diff --git a/core/java/android/hardware/camera2/CaptureRequest.java b/core/java/android/hardware/camera2/CaptureRequest.java index f096f5c31531..731c0bdb34d1 100644 --- a/core/java/android/hardware/camera2/CaptureRequest.java +++ b/core/java/android/hardware/camera2/CaptureRequest.java @@ -870,10 +870,20 @@ public final class CaptureRequest extends CameraMetadata implements Parcelable { new Key("android.lens.aperture", float.class); /** - *

State of lens neutral density - * filter(s)

- *

Will not be supported on most devices. Can only - * pick from supported list

+ *

State of lens neutral density filter(s).

+ *

This will not be supported on most camera devices. On devices + * where this is supported, this may only be set to one of the + * values included in {@link CameraCharacteristics#LENS_INFO_AVAILABLE_FILTER_DENSITIES android.lens.info.availableFilterDensities}.

+ *

Lens filters are typically used to lower the amount of light the + * sensor is exposed to (measured in steps of EV). As used here, an EV + * step is the standard logarithmic representation, which are + * non-negative, and inversely proportional to the amount of light + * hitting the sensor. For example, setting this to 0 would result + * in no reduction of the incoming light, and setting this to 2 would + * mean that the filter is set to reduce incoming light by two stops + * (allowing 1/4 of the prior amount of light to the sensor).

+ * + * @see CameraCharacteristics#LENS_INFO_AVAILABLE_FILTER_DENSITIES */ public static final Key LENS_FILTER_DENSITY = new Key("android.lens.filterDensity", float.class); diff --git a/core/java/android/hardware/camera2/CaptureResult.java b/core/java/android/hardware/camera2/CaptureResult.java index 3ac47fa8b944..e54fb5128fa5 100644 --- a/core/java/android/hardware/camera2/CaptureResult.java +++ b/core/java/android/hardware/camera2/CaptureResult.java @@ -1078,10 +1078,20 @@ public final class CaptureResult extends CameraMetadata { new Key("android.lens.aperture", float.class); /** - *

State of lens neutral density - * filter(s)

- *

Will not be supported on most devices. Can only - * pick from supported list

+ *

State of lens neutral density filter(s).

+ *

This will not be supported on most camera devices. On devices + * where this is supported, this may only be set to one of the + * values included in {@link CameraCharacteristics#LENS_INFO_AVAILABLE_FILTER_DENSITIES android.lens.info.availableFilterDensities}.

+ *

Lens filters are typically used to lower the amount of light the + * sensor is exposed to (measured in steps of EV). As used here, an EV + * step is the standard logarithmic representation, which are + * non-negative, and inversely proportional to the amount of light + * hitting the sensor. For example, setting this to 0 would result + * in no reduction of the incoming light, and setting this to 2 would + * mean that the filter is set to reduce incoming light by two stops + * (allowing 1/4 of the prior amount of light to the sensor).

+ * + * @see CameraCharacteristics#LENS_INFO_AVAILABLE_FILTER_DENSITIES */ public static final Key LENS_FILTER_DENSITY = new Key("android.lens.filterDensity", float.class); -- 2.11.0