From b7951bac01681e5f6d08f10061584e87f9c4b32a Mon Sep 17 00:00:00 2001 From: Austin Borger Date: Fri, 24 Mar 2023 16:39:27 -0700 Subject: [PATCH] Camera2: Add documentation for the TestApi getCameraCharacteristics. Bug: 274993995 Test: m sdk Change-Id: If15e3014986f64a6e53384693800b45dab5b302b --- .../android/hardware/camera2/CameraManager.java | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/core/java/android/hardware/camera2/CameraManager.java b/core/java/android/hardware/camera2/CameraManager.java index 144b1de148b49..c174fd55577b2 100644 --- a/core/java/android/hardware/camera2/CameraManager.java +++ b/core/java/android/hardware/camera2/CameraManager.java @@ -627,6 +627,21 @@ public final class CameraManager { } /** + *

Query the capabilities of a camera device. These capabilities are + * immutable for a given camera.

+ * + *

The value of {@link CameraCharacteristics.SENSOR_ORIENTATION} will change for landscape + * cameras depending on whether overrideToPortrait is enabled. If enabled, these cameras will + * appear to be portrait orientation instead, provided that the override is supported by the + * camera device. Only devices that can be opened by {@link #openCamera} will report a changed + * {@link CameraCharacteristics.SENSOR_ORIENTATION}.

+ * + * @param cameraId The id of the camera device to query. This could be either a standalone + * camera ID which can be directly opened by {@link #openCamera}, or a physical camera ID that + * can only used as part of a logical multi-camera. + * @param overrideToPortrait Whether to apply the landscape to portrait override. + * @return The properties of the given camera + * * @hide */ @TestApi