From 46f82f0adee2ff7d5681a378a5cc6cb3670a028d Mon Sep 17 00:00:00 2001
From: Zhijun He
Date: Tue, 20 May 2014 18:22:18 -0700
Subject: [PATCH] camera_metadata: Clarify shading map spec
The existing spec is unclear about shading map calculation for both application
developer and hal implementers, need more clarification.
Also fix a typo in tonemap.mode.
Bug: 15168075
Change-Id: I7f38ccf6aa6938fdac9f64e95deddc0188025d08
---
camera/docs/docs.html | 38 ++++++++++++++++++++++++++++++++-----
camera/docs/metadata_properties.xml | 22 +++++++++++++++++++--
2 files changed, 53 insertions(+), 7 deletions(-)
diff --git a/camera/docs/docs.html b/camera/docs/docs.html
index bba05ad6..167d4e45 100644
--- a/camera/docs/docs.html
+++ b/camera/docs/docs.html
@@ -16629,7 +16629,13 @@ shown below:
camera device. Applications can request lens shading map data by setting
android.statistics.lensShadingMapMode to ON, and then the camera device will provide
lens shading map data in android.statistics.lensShadingMap, with size specified
-by android.lens.info.shadingMapSize.
+by android.lens.info.shadingMapSize; the returned shading map data will be the one
+applied by the camera device for this capture request.
+The shading map data may depend on the AE and AWB statistics, therefore the reliability
+of the map data may be affected by the AE and AWB algorithms. When AE and AWB are in
+AUTO modes(android.control.aeMode !=
OFF and android.control.awbMode !=
OFF),
+to get best results, it is recommended that the applications wait for the AE and AWB to
+be converged before using the returned shading map data.
@@ -16774,7 +16780,13 @@ shown below:
camera device. Applications can request lens shading map data by setting
android.statistics.lensShadingMapMode to ON, and then the camera device will provide
lens shading map data in android.statistics.lensShadingMap, with size specified
-by android.lens.info.shadingMapSize.
+by android.lens.info.shadingMapSize; the returned shading map data will be the one
+applied by the camera device for this capture request.
+The shading map data may depend on the AE and AWB statistics, therefore the reliability
+of the map data may be affected by the AE and AWB algorithms. When AE and AWB are in
+AUTO modes(android.control.aeMode !=
OFF and android.control.awbMode !=
OFF),
+to get best results, it is recommended that the applications wait for the AE and AWB to
+be converged before using the returned shading map data.
@@ -17998,7 +18010,7 @@ generation
+ " rowspan="5">
android.statistics.lensShadingMap
|
@@ -18079,6 +18091,22 @@ image of a gray wall (using bicubic interpolation for visual quality) as capture
|
+
+
+
+ The lens shading map calculation may depend on exposure and white balance statistics.
+When AE and AWB are in AUTO modes
+(android.control.aeMode != OFF and android.control.awbMode != OFF), the HAL
+may have all the information it need to generate most accurate lens shading map. When
+AE or AWB are in manual mode
+(android.control.aeMode == OFF or android.control.awbMode == OFF), the shading map
+may be adversely impacted by manual exposure or white balance parameters. To avoid
+generating unreliable shading map data, the HAL may choose to lock the shading map with
+the latest known good map generated when the AE and AWB are in AUTO modes.
+ |
+
|
@@ -18781,7 +18809,7 @@ emit its own tonemap curve in andro
android.tonemap.curveGreen, and android.tonemap.curveBlue.
These values are always available, and as close as possible to the
actually used nonlinear/nonglobal transforms.
-If a request is sent with TRANSFORM_MATRIX with the camera device's
+
If a request is sent with CONTRAST_CURVE with the camera device's
provided curve in FAST or HIGH_QUALITY, the image's tonemap will be
roughly the same.
@@ -19243,7 +19271,7 @@ emit its own tonemap curve in andro
android.tonemap.curveGreen, and android.tonemap.curveBlue.
These values are always available, and as close as possible to the
actually used nonlinear/nonglobal transforms.
-If a request is sent with TRANSFORM_MATRIX with the camera device's
+
If a request is sent with CONTRAST_CURVE with the camera device's
provided curve in FAST or HIGH_QUALITY, the image's tonemap will be
roughly the same.
diff --git a/camera/docs/metadata_properties.xml b/camera/docs/metadata_properties.xml
index 96b2c351..4c513eed 100644
--- a/camera/docs/metadata_properties.xml
+++ b/camera/docs/metadata_properties.xml
@@ -4770,7 +4770,14 @@ xsi:schemaLocation="http://schemas.android.com/service/camera/metadata/ metadata
camera device. Applications can request lens shading map data by setting
android.statistics.lensShadingMapMode to ON, and then the camera device will provide
lens shading map data in android.statistics.lensShadingMap, with size specified
- by android.lens.info.shadingMapSize.
+ by android.lens.info.shadingMapSize; the returned shading map data will be the one
+ applied by the camera device for this capture request.
+
+ The shading map data may depend on the AE and AWB statistics, therefore the reliability
+ of the map data may be affected by the AE and AWB algorithms. When AE and AWB are in
+ AUTO modes(android.control.aeMode `!=` OFF and android.control.awbMode `!=` OFF),
+ to get best results, it is recommended that the applications wait for the AE and AWB to
+ be converged before using the returned shading map data.
@@ -5069,6 +5076,17 @@ xsi:schemaLocation="http://schemas.android.com/service/camera/metadata/ metadata
![Image of a uniform white wall (inverse shading map)](android.statistics.lensShadingMap/inv_shading.png)
+
+ The lens shading map calculation may depend on exposure and white balance statistics.
+ When AE and AWB are in AUTO modes
+ (android.control.aeMode `!=` OFF and android.control.awbMode `!=` OFF), the HAL
+ may have all the information it need to generate most accurate lens shading map. When
+ AE or AWB are in manual mode
+ (android.control.aeMode `==` OFF or android.control.awbMode `==` OFF), the shading map
+ may be adversely impacted by manual exposure or white balance parameters. To avoid
+ generating unreliable shading map data, the HAL may choose to lock the shading map with
+ the latest known good map generated when the AE and AWB are in AUTO modes.
+