Introduction
Devices running Android 9 or higher can support monochrome cameras.
Android 10 provides additional support for the Y8 stream format, monochrome and near-infrared (NIR) color filter array static metadata, and DngCreator
functions for monochrome cameras.
With this capability, device manufacturers can implement a monochrome or NIR camera device and reduce memory use by using the Y8 stream format.
A monochrome camera can serve as the underlying physical camera of a logical multi-camera device to achieve better low-light noise characteristics.
Implementation
Hardware requirements
To implement this feature, your device must have a monochrome camera sensor and an image signal processor (ISP) to process the sensor output.
Implementing a monochrome camera
To advertise a camera device as a monochrome camera, the Camera HAL must meet the following requirements:
android.sensor.info.colorFilterArray
is set toMONO
orNIR
.BACKWARD_COMPATIBLE
required keys are supported andMANUAL_POST_PROCESSING
isn't supported.android.control.awbAvailableModes
only containsAUTO
andandroid.control.awbState
is eitherCONVERTED
orLOCKED
depending onandroid.control.awbLock
.android.colorCorrection.mode
,android.colorCorrection.transform
, andandroid.colorCorrection.gains
aren't in available request and result keys. As a result, the camera device isLIMITED
.-
The following color-related static metadata keys aren't present:
android.sensor.referenceIlluminant*
android.sensor.calibrationTransform*
android.sensor.colorTransform*
android.sensor.forwardMatrix*
android.sensor.neutralColorPoint
android.sensor.greenSplit
-
All color channels have the same values for the following metadata keys:
android.sensor.blackLevelPattern
android.sensor.dynamicBlackLevel
android.statistics.lensShadingMap
android.tonemap.curve
-
android.sensor.noiseProfile
has only one color channel.
For monochrome devices supporting Y8 stream formats, the Camera HAL must support swapping YUV_420_888
formats in mandatory stream combinations (including reprocessing) with Y8 formats.
The following public APIs are used in this feature:
- Y8 image format
- SENSOR_INFO_COLOR_FILTER_ARRANGEMENT_MONO
- SENSOR_INFO_COLOR_FILTER_ARRANGEMENT_NIR
- MONOCHROME camera capability (introduced in Android 9)
For more details on the Camera HAL, see docs.html. For more information on related public APIs, seeImageFormat, CameraCharacteristics, CaptureRequest, and CaptureResult.
Validation
To validate your implementation of a monochrome camera, run the following CTS and VTS tests.
CTS tests
testMonochromeCharacteristics
CaptureRequestTest
CaptureResultTest
StillCaptureTest
DngCreatorTest
VTS tests
getCameraCharacteristics
processMultiCaptureRequestPreview