Camera: Add doc for combined stream usage flags
Specify the HAL behavior when stream usage flag is combination for
multiple consumers.
Test: Compile
Bug: 33777818
Change-Id: I97e7bcc79ee36a395210c7cf8deefc4f175d3e07
diff --git a/camera/device/3.2/ICameraDeviceSession.hal b/camera/device/3.2/ICameraDeviceSession.hal
index e92d756..a4816b4 100644
--- a/camera/device/3.2/ICameraDeviceSession.hal
+++ b/camera/device/3.2/ICameraDeviceSession.hal
@@ -152,6 +152,7 @@
* camera3_stream_configuration_t->operation_mode requirements
* for non-NORMAL mode, or the requested operation_mode is not
* supported by the HAL.
+ * - Unsupported usage flag
* The camera service cannot filter out all possible illegal stream
* configurations, since some devices may support more simultaneous
* streams or larger stream resolutions than the minimum required
diff --git a/camera/device/3.2/types.hal b/camera/device/3.2/types.hal
index c7d38c1..ba5bbe0 100644
--- a/camera/device/3.2/types.hal
+++ b/camera/device/3.2/types.hal
@@ -248,6 +248,12 @@
* streamType INPUT, the value of this field is always 0. For all streams
* passed via configureStreams(), the HAL must set its own
* additional usage flags in its output HalStreamConfiguration.
+ *
+ * The usage flag for an output stream may be bitwise combination of usage
+ * flags for multiple consumers, for the purpose of sharing one camera
+ * stream between those consumers. The HAL must fail configureStreams call
+ * with ILLEGAL_ARGUMENT if the combined flags cannot be supported due to
+ * imcompatible buffer format, dataSpace, or other hardware limitations.
*/
ConsumerUsageFlags usage;