Fixes ycbcr image properties requirement
authorMatthew Netsch <quic_mnetsch@quicinc.com>
Wed, 16 Jan 2019 19:36:30 +0000 (14:36 -0500)
committerAlexander Galazin <Alexander.Galazin@arm.com>
Fri, 18 Jan 2019 08:46:22 +0000 (03:46 -0500)
Mipmaps/Arrays are optional for ycbcr images

Components: Vulkan
VK-GL-CTS issue: 1506

Affects:
dEQP-VK.api.info.image_format_properties.*

Change-Id: I795ec1c8b3e44a460ddd0c7c2fe0fe1731794cab
(cherry picked from commit 845394de5b43c71adddc72e7563b50c65e852b27)

external/vulkancts/modules/vulkan/api/vktApiFeatureInfo.cpp

index f7c3733..5fd7724 100644 (file)
@@ -2514,9 +2514,10 @@ tcu::TestStatus imageFormatProperties (Context& context, const VkFormat format,
                                                                                                                                        properties.maxExtent.height     >= deviceLimits.maxImageDimension3D &&
                                                                                                                                        properties.maxExtent.depth      >= deviceLimits.maxImageDimension3D),
                                                                  "Reported dimensions smaller than device limits");
-                                       results.check(properties.maxMipLevels == fullMipPyramidSize, "maxMipLevels is not full mip pyramid size");
-                                       results.check(imageType == VK_IMAGE_TYPE_3D || properties.maxArrayLayers >= deviceLimits.maxImageArrayLayers,
-                                                                 "maxArrayLayers smaller than device limits");
+                                       results.check((isYCbCrFormat(format) && (properties.maxMipLevels == 1)) || properties.maxMipLevels == fullMipPyramidSize,
+                                                     "Invalid mip pyramid size");
+                                       results.check((isYCbCrFormat(format) && (properties.maxArrayLayers == 1)) || imageType == VK_IMAGE_TYPE_3D ||
+                                                     properties.maxArrayLayers >= deviceLimits.maxImageArrayLayers, "Invalid maxArrayLayers");
                                }
                                else
                                {