Commit aad8cfca by Chris Forbes

Add feature support check for VkPhysicalDeviceMultiviewFeatures

Newer Vulkan CTS has started providing this extension structure during device creation. Bug: b/139528538 Change-Id: Ied17274d95acb8be1766f62e21fcc1c6b7594015 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/35249Tested-by: 's avatarChris Forbes <chrisforbes@google.com> Kokoro-Presubmit: kokoro <noreply+kokoro@google.com> Reviewed-by: 's avatarNicolas Capens <nicolascapens@google.com>
parent 303ddb5c
......@@ -507,6 +507,18 @@ VKAPI_ATTR VkResult VKAPI_CALL vkCreateDevice(VkPhysicalDevice physicalDevice, c
}
}
break;
case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_MULTIVIEW_FEATURES:
{
const VkPhysicalDeviceMultiviewFeatures* multiviewFeatures = reinterpret_cast<const VkPhysicalDeviceMultiviewFeatures*>(extensionCreateInfo);
if (multiviewFeatures->multiview ||
multiviewFeatures->multiviewGeometryShader ||
multiviewFeatures->multiviewTessellationShader)
{
return VK_ERROR_FEATURE_NOT_PRESENT;
}
}
break;
default:
// "the [driver] must skip over, without processing (other than reading the sType and pNext members) any structures in the chain with sType values not defined by [supported extenions]"
UNIMPLEMENTED("extensionCreateInfo->sType %d", int(extensionCreateInfo->sType)); // TODO(b/119321052): UNIMPLEMENTED() should be used only for features that must still be implemented. Use a more informational macro here.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment