camera.device@3.4: Add MOTION_TRACKING template enums
- Extend RequestTemplate with two new values
- Add legacy wrapper support for the new templates
Test: Builds, camera continues to run. CTS coverage of templates
tests new templates as expected.
Bug: 63629224
Change-Id: I2a44d86a815690798fa4b8327794c64716d134ee
diff --git a/camera/device/3.4/ICameraDeviceSession.hal b/camera/device/3.4/ICameraDeviceSession.hal
index 4ce749d..7afcf94 100644
--- a/camera/device/3.4/ICameraDeviceSession.hal
+++ b/camera/device/3.4/ICameraDeviceSession.hal
@@ -17,6 +17,7 @@
package android.hardware.camera.device@3.4;
import android.hardware.camera.common@1.0::Status;
+import @3.2::CameraMetadata;
import @3.3::ICameraDeviceSession;
import @3.3::HalStreamConfiguration;
import @3.2::BufferCache;
@@ -30,6 +31,43 @@
interface ICameraDeviceSession extends @3.3::ICameraDeviceSession {
/**
+ * constructDefaultRequestSettings_3_4:
+ *
+ * Create capture settings for standard camera use cases. Supports the
+ * new template enums added in @3.4.
+ *
+ * The device must return a settings buffer that is configured to meet the
+ * requested use case, which must be one of the CAMERA3_TEMPLATE_*
+ * enums. All request control fields must be included.
+ *
+ * Performance requirements:
+ *
+ * This must be a non-blocking call. The HAL should return from this call
+ * in 1ms, and must return from this call in 5ms.
+ *
+ * Return values:
+ * @return status Status code for the operation, one of:
+ * OK:
+ * On a successful construction of default settings.
+ * INTERNAL_ERROR:
+ * An unexpected internal error occurred, and the default settings
+ * are not available.
+ * ILLEGAL_ARGUMENT:
+ * The camera HAL does not support the input template type
+ * CAMERA_DISCONNECTED:
+ * An external camera device has been disconnected, and is no longer
+ * available. This camera device interface is now stale, and a new
+ * instance must be acquired if the device is reconnected. All
+ * subsequent calls on this interface must return
+ * CAMERA_DISCONNECTED.
+ * @return requestTemplate The default capture request settings for the requested
+ * use case, or an empty metadata structure if status is not OK.
+ *
+ */
+ constructDefaultRequestSettings_3_4(RequestTemplate type) generates
+ (Status status, @3.2::CameraMetadata requestTemplate);
+
+ /**
* configureStreams_3_4:
*
* Identical to @3.3::ICameraDeviceSession.configureStreams, except that: