@@ -1342,6 +1342,16 @@ int CameraCapabilities::initializeStaticMetadata()
whiteLevel);
availableCharacteristicsKeys_.insert(ANDROID_SENSOR_INFO_WHITE_LEVEL);
+ /* This is required for FULL. */
+ std::vector<int32_t> blackLevels = { 0, 0, 0, 0 };
+ if (properties.contains(properties::SensorFixedBlackLevels)) {
+ const Span<const int32_t> &vals =
+ properties.get(properties::SensorFixedBlackLevels);
+ blackLevels = std::vector<int32_t>(vals.begin(), vals.end());
+ }
+ staticMetadata_->addEntry(ANDROID_SENSOR_BLACK_LEVEL_PATTERN, blackLevels);
+ availableCharacteristicsKeys_.insert(ANDROID_SENSOR_BLACK_LEVEL_PATTERN);
+
/* Statistics static metadata. */
uint8_t faceDetectMode = ANDROID_STATISTICS_FACE_DETECT_MODE_OFF;
staticMetadata_->addEntry(ANDROID_STATISTICS_INFO_AVAILABLE_FACE_DETECT_MODES,
Plumb SENSOR_BLACK_LEVEL_PATTERN into the static metadata. Get the information from the sensor database. Note that nothing is added to the capability detector, as black level pattern will always be added to the static metadata. Add a comment to document it. Bug: https://bugs.libcamera.org/show_bug.cgi?id=48 Signed-off-by: Paul Elder <paul.elder@ideasonboard.com> --- src/android/camera_capabilities.cpp | 10 ++++++++++ 1 file changed, 10 insertions(+)