From cc87d8f2380ed34de6d97a604b56caf5583e7dcf Mon Sep 17 00:00:00 2001 From: Jag Saund Date: Mon, 14 Oct 2024 23:44:47 +0000 Subject: [PATCH] Night Mode Indicator - adds a night mode indicator API for Camera2 - auto generated files Flag: com.android.internal.camera.flags.night_mode_indicator Test: atest -c -d cts/tests/camera/src/android/hardware/camera2/cts/CameraExtensionSessionTest.java Bug: 335902696 Change-Id: Icdd66813f7ef5e03c8a181c285128cdf8f1c1ca1 --- .../camera/metadata/CameraMetadataTag.aidl | 1 + .../metadata/ExtensionNightModeIndicator.aidl | 44 +++++++++++++++++++ .../metadata/SensorReadoutTimestamp.aidl | 2 +- .../camera/metadata/CameraMetadataTag.aidl | 13 +++++- .../metadata/ExtensionNightModeIndicator.aidl | 36 +++++++++++++++ 5 files changed, 94 insertions(+), 2 deletions(-) create mode 100644 camera/metadata/aidl/aidl_api/android.hardware.camera.metadata/current/android/hardware/camera/metadata/ExtensionNightModeIndicator.aidl create mode 100644 camera/metadata/aidl/android/hardware/camera/metadata/ExtensionNightModeIndicator.aidl diff --git a/camera/metadata/aidl/aidl_api/android.hardware.camera.metadata/current/android/hardware/camera/metadata/CameraMetadataTag.aidl b/camera/metadata/aidl/aidl_api/android.hardware.camera.metadata/current/android/hardware/camera/metadata/CameraMetadataTag.aidl index 48beab05b7..36356ff216 100644 --- a/camera/metadata/aidl/aidl_api/android.hardware.camera.metadata/current/android/hardware/camera/metadata/CameraMetadataTag.aidl +++ b/camera/metadata/aidl/aidl_api/android.hardware.camera.metadata/current/android/hardware/camera/metadata/CameraMetadataTag.aidl @@ -357,6 +357,7 @@ enum CameraMetadataTag { ANDROID_HEIC_INFO_MAX_JPEG_APP_SEGMENTS_COUNT, ANDROID_AUTOMOTIVE_LOCATION = android.hardware.camera.metadata.CameraMetadataSectionStart.ANDROID_AUTOMOTIVE_START /* 1966080 */, ANDROID_AUTOMOTIVE_LENS_FACING = android.hardware.camera.metadata.CameraMetadataSectionStart.ANDROID_AUTOMOTIVE_LENS_START /* 2031616 */, + ANDROID_EXTENSION_NIGHT_MODE_INDICATOR = 2097154, ANDROID_JPEGR_AVAILABLE_JPEG_R_STREAM_CONFIGURATIONS = android.hardware.camera.metadata.CameraMetadataSectionStart.ANDROID_JPEGR_START /* 2162688 */, ANDROID_JPEGR_AVAILABLE_JPEG_R_MIN_FRAME_DURATIONS, ANDROID_JPEGR_AVAILABLE_JPEG_R_STALL_DURATIONS, diff --git a/camera/metadata/aidl/aidl_api/android.hardware.camera.metadata/current/android/hardware/camera/metadata/ExtensionNightModeIndicator.aidl b/camera/metadata/aidl/aidl_api/android.hardware.camera.metadata/current/android/hardware/camera/metadata/ExtensionNightModeIndicator.aidl new file mode 100644 index 0000000000..6cfdc02d82 --- /dev/null +++ b/camera/metadata/aidl/aidl_api/android.hardware.camera.metadata/current/android/hardware/camera/metadata/ExtensionNightModeIndicator.aidl @@ -0,0 +1,44 @@ +/* + * Copyright (C) 2024 The Android Open Source Project + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + *//* + * Autogenerated from camera metadata definitions in + * /system/media/camera/docs/metadata_definitions.xml + * *** DO NOT EDIT BY HAND *** + */ +/////////////////////////////////////////////////////////////////////////////// +// THIS FILE IS IMMUTABLE. DO NOT EDIT IN ANY CASE. // +/////////////////////////////////////////////////////////////////////////////// + +// This file is a snapshot of an AIDL file. Do not edit it manually. There are +// two cases: +// 1). this is a frozen version file - do not edit this in any case. +// 2). this is a 'current' file. If you make a backwards compatible change to +// the interface (from the latest frozen version), the build system will +// prompt you to update this file with `m -update-api`. +// +// You must not make a backward incompatible change to any AIDL file built +// with the aidl_interface module type with versions property set. The module +// type is used to build AIDL files in a way that they can be used across +// independently updatable components of the system. If a device is shipped +// with such a backward incompatible change, it has a high risk of breaking +// later when a module using the interface is updated, e.g., Mainline modules. + +package android.hardware.camera.metadata; +@Backing(type="int") @VintfStability +enum ExtensionNightModeIndicator { + ANDROID_EXTENSION_NIGHT_MODE_INDICATOR_UNKNOWN, + ANDROID_EXTENSION_NIGHT_MODE_INDICATOR_OFF, + ANDROID_EXTENSION_NIGHT_MODE_INDICATOR_ON, +} diff --git a/camera/metadata/aidl/aidl_api/android.hardware.camera.metadata/current/android/hardware/camera/metadata/SensorReadoutTimestamp.aidl b/camera/metadata/aidl/aidl_api/android.hardware.camera.metadata/current/android/hardware/camera/metadata/SensorReadoutTimestamp.aidl index 35dc1a976f..11be18ef06 100644 --- a/camera/metadata/aidl/aidl_api/android.hardware.camera.metadata/current/android/hardware/camera/metadata/SensorReadoutTimestamp.aidl +++ b/camera/metadata/aidl/aidl_api/android.hardware.camera.metadata/current/android/hardware/camera/metadata/SensorReadoutTimestamp.aidl @@ -1,5 +1,5 @@ /* - * Copyright (C) 2024 The Android Open Source Project + * Copyright (C) 2022 The Android Open Source Project * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/camera/metadata/aidl/android/hardware/camera/metadata/CameraMetadataTag.aidl b/camera/metadata/aidl/android/hardware/camera/metadata/CameraMetadataTag.aidl index 7e9ee754f5..5ab71b0b11 100644 --- a/camera/metadata/aidl/android/hardware/camera/metadata/CameraMetadataTag.aidl +++ b/camera/metadata/aidl/android/hardware/camera/metadata/CameraMetadataTag.aidl @@ -2404,7 +2404,11 @@ enum CameraMetadataTag { * *

The available HEIC (ISO/IEC 23008-12/24) UltraHDR stream * configurations that this camera device supports - * (i.e. format, width, height, output/input stream).

+ * (i.e. format, width, height, output/input stream) for CaptureRequests where + * ANDROID_SENSOR_PIXEL_MODE is set to + * CameraMetadata#SENSOR_PIXEL_MODE_MAXIMUM_RESOLUTION.

+ * + * @see ANDROID_SENSOR_PIXEL_MODE */ ANDROID_HEIC_AVAILABLE_HEIC_ULTRA_HDR_STREAM_CONFIGURATIONS_MAXIMUM_RESOLUTION, /** @@ -2458,6 +2462,13 @@ enum CameraMetadataTag { * passenger seats.

*/ ANDROID_AUTOMOTIVE_LENS_FACING = CameraMetadataSectionStart.ANDROID_AUTOMOTIVE_LENS_START, + /** + * android.extension.nightModeIndicator [dynamic, enum, public] + * + *

Indicates when to activate Night Mode Camera Extension for high-quality + * still captures in low-light conditions.

+ */ + ANDROID_EXTENSION_NIGHT_MODE_INDICATOR = 2097154, /** * android.jpegr.availableJpegRStreamConfigurations [static, enum[], ndk_public] * diff --git a/camera/metadata/aidl/android/hardware/camera/metadata/ExtensionNightModeIndicator.aidl b/camera/metadata/aidl/android/hardware/camera/metadata/ExtensionNightModeIndicator.aidl new file mode 100644 index 0000000000..3c3bdf573f --- /dev/null +++ b/camera/metadata/aidl/android/hardware/camera/metadata/ExtensionNightModeIndicator.aidl @@ -0,0 +1,36 @@ +/* + * Copyright (C) 2024 The Android Open Source Project + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/* + * Autogenerated from camera metadata definitions in + * /system/media/camera/docs/metadata_definitions.xml + * *** DO NOT EDIT BY HAND *** + */ + +package android.hardware.camera.metadata; + +/** + * android.extension.nightModeIndicator enumeration values + * @see ANDROID_EXTENSION_NIGHT_MODE_INDICATOR + * See system/media/camera/docs/metadata_definitions.xml for details. + */ +@VintfStability +@Backing(type="int") +enum ExtensionNightModeIndicator { + ANDROID_EXTENSION_NIGHT_MODE_INDICATOR_UNKNOWN, + ANDROID_EXTENSION_NIGHT_MODE_INDICATOR_OFF, + ANDROID_EXTENSION_NIGHT_MODE_INDICATOR_ON, +}