Camera: Add dynamic depth tags and dataspace

Add necessary metadata tags for supporting dynamic depth
streams.
Includes minor gfx fix which should help eliminate build
errors after HIDL header autogen.

Bug: 109735087
Test: vts-tradefed run commandAndExit vts --skip-all-system-status-check
    --skip-preconditions --module VtsHalCameraProviderV2_4Target -l INFO
Change-Id: Ia476b195095ae7a29bc740174331dfbfdaa6d320
This commit is contained in:
Emilian Peev
2019-01-04 13:01:05 +00:00
parent 543d779efa
commit 5f103998ff
3 changed files with 55 additions and 0 deletions

View File

@@ -73,6 +73,28 @@ enum CameraMetadataTag : @3.3::CameraMetadataTag {
*/
ANDROID_DEPTH_AVAILABLE_RECOMMENDED_DEPTH_STREAM_CONFIGURATIONS = android.hardware.camera.metadata@3.2::CameraMetadataTag:ANDROID_DEPTH_END,
/** android.depth.availableDynamicDepthStreamConfigurations [static, enum[], ndk_public]
*
* <p>The available dynamic depth dataspace stream
* configurations that this camera device supports
* (i.e. format, width, height, output/input stream).</p>
*/
ANDROID_DEPTH_AVAILABLE_DYNAMIC_DEPTH_STREAM_CONFIGURATIONS,
/** android.depth.availableDynamicDepthMinFrameDurations [static, int64[], ndk_public]
*
* <p>This lists the minimum frame duration for each
* format/size combination for dynamic depth output streams.</p>
*/
ANDROID_DEPTH_AVAILABLE_DYNAMIC_DEPTH_MIN_FRAME_DURATIONS,
/** android.depth.availableDynamicDepthStallDurations [static, int64[], ndk_public]
*
* <p>This lists the maximum stall duration for each
* output format/size combination for dynamic depth streams.</p>
*/
ANDROID_DEPTH_AVAILABLE_DYNAMIC_DEPTH_STALL_DURATIONS,
ANDROID_DEPTH_END_3_4,
/** android.logicalMultiCamera.activePhysicalId [dynamic, byte, public]
@@ -136,3 +158,11 @@ enum CameraMetadataEnumAndroidSensorInfoColorFilterArrangement :
enum CameraMetadataEnumAndroidInfoSupportedBufferManagementVersion : uint32_t {
ANDROID_INFO_SUPPORTED_BUFFER_MANAGEMENT_VERSION_HIDL_DEVICE_3_5,
};
/** android.depth.availableDynamicDepthStreamConfigurations enumeration values
* @see ANDROID_DEPTH_AVAILABLE_DYNAMIC_DEPTH_STREAM_CONFIGURATIONS
*/
enum CameraMetadataEnumAndroidDepthAvailableDynamicDepthStreamConfigurations : uint32_t {
ANDROID_DEPTH_AVAILABLE_DYNAMIC_DEPTH_STREAM_CONFIGURATIONS_OUTPUT,
ANDROID_DEPTH_AVAILABLE_DYNAMIC_DEPTH_STREAM_CONFIGURATIONS_INPUT,
};

View File

@@ -5521,6 +5521,24 @@ void CameraHidlTest::verifyCameraCharacteristics(Status status, const CameraMeta
ADD_FAILURE() << "ANDROID_REQUEST_CHARACTERISTIC_KEYS_NEEDING_PERMISSION "
<< " per API contract should never be set by Hal!";
}
retcode = find_camera_metadata_ro_entry(metadata,
ANDROID_DEPTH_AVAILABLE_DYNAMIC_DEPTH_STREAM_CONFIGURATIONS, &entry);
if ((0 == retcode) || (entry.count > 0)) {
ADD_FAILURE() << "ANDROID_DEPTH_AVAILABLE_DYNAMIC_DEPTH_STREAM_CONFIGURATIONS"
<< " per API contract should never be set by Hal!";
}
retcode = find_camera_metadata_ro_entry(metadata,
ANDROID_DEPTH_AVAILABLE_DYNAMIC_DEPTH_MIN_FRAME_DURATIONS, &entry);
if ((0 == retcode) || (entry.count > 0)) {
ADD_FAILURE() << "ANDROID_DEPTH_AVAILABLE_DYNAMIC_DEPTH_MIN_FRAME_DURATIONS"
<< " per API contract should never be set by Hal!";
}
retcode = find_camera_metadata_ro_entry(metadata,
ANDROID_DEPTH_AVAILABLE_DYNAMIC_DEPTH_STALL_DURATIONS, &entry);
if ((0 == retcode) || (entry.count > 0)) {
ADD_FAILURE() << "ANDROID_DEPTH_AVAILABLE_DYNAMIC_DEPTH_STALL_DURATIONS"
<< " per API contract should never be set by Hal!";
}
}
void CameraHidlTest::verifyMonochromeCharacteristics(const CameraMetadata& chars,

View File

@@ -42,6 +42,13 @@ enum Dataspace : @1.1::Dataspace {
* Use full range, sRGB transfer and BT2020 standard
*/
DISPLAY_BT2020 = STANDARD_BT2020 | TRANSFER_SRGB | RANGE_FULL,
/**
* ISO 16684-1:2011(E)
*
* Embedded depth metadata following the dynamic depth specification.
*/
DYNAMIC_DEPTH = 0x1002,
};
enum ColorMode : @1.1::ColorMode {