From: Graeme Leese Date: Mon, 18 Sep 2017 23:58:22 +0000 (+0100) Subject: Check viewport limits against framebuffer limits X-Git-Tag: upstream/1.3.5~2565^2~125^2~7 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=1fad3774963a28bfeadde131a1385525a0e24bb5;p=platform%2Fupstream%2FVK-GL-CTS.git Check viewport limits against framebuffer limits They were being checked against the maximum image dimensions which was incorrect. Affects: dEQP-VK.api.info.device.properties Components: Vulkan VK-GL-CTS Issue: 700 Change-Id: Ia11bb69439294c5160d2da0a432ef8fc38e33500 (cherry picked from commit 0bef80fc45e49e9486f238e1b5b52a2aae4c530c) --- diff --git a/external/vulkancts/modules/vulkan/api/vktApiFeatureInfo.cpp b/external/vulkancts/modules/vulkan/api/vktApiFeatureInfo.cpp index 4b1e85b..06c5e94 100644 --- a/external/vulkancts/modules/vulkan/api/vktApiFeatureInfo.cpp +++ b/external/vulkancts/modules/vulkan/api/vktApiFeatureInfo.cpp @@ -464,14 +464,14 @@ bool validateFeatureLimits(VkPhysicalDeviceProperties* properties, VkPhysicalDev } } - for (deUint32 ndx = 0; ndx < DE_LENGTH_OF_ARRAY(limits->maxViewportDimensions); ndx++) + if (limits->maxFramebufferWidth > limits->maxViewportDimensions[0] || + limits->maxFramebufferHeight > limits->maxViewportDimensions[1]) { - if (limits->maxImageDimension2D > limits->maxViewportDimensions[ndx]) - { - log << TestLog::Message << "limit validation failed, maxImageDimension2D of " << limits->maxImageDimension2D - << "is larger than maxViewportDimension[" << ndx << "] of " << limits->maxViewportDimensions[ndx] << TestLog::EndMessage; - limitsOk = false; - } + log << TestLog::Message << "limit validation failed, maxFramebufferDimension of " + << "[" << limits->maxFramebufferWidth << ", " << limits->maxFramebufferHeight << "] " + << "is larger than maxViewportDimension of " + << "[" << limits->maxViewportDimensions[0] << ", " << limits->maxViewportDimensions[1] << "]" << TestLog::EndMessage; + limitsOk = false; } if (limits->viewportBoundsRange[0] > float(-2 * limits->maxViewportDimensions[0]))