anv: Add the KHX_multiview boilerplate

Reviewed-by: Iago Toral Quiroga <itoral@igalia.com>
This commit is contained in:
Jason Ekstrand
2017-03-21 14:40:46 -07:00
parent 0bed97006f
commit e997f548de
2 changed files with 18 additions and 0 deletions

View File

@@ -612,6 +612,15 @@ void anv_GetPhysicalDeviceFeatures2KHR(
vk_foreach_struct(ext, pFeatures->pNext) { vk_foreach_struct(ext, pFeatures->pNext) {
switch (ext->sType) { switch (ext->sType) {
case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_MULTIVIEW_FEATURES_KHX: {
VkPhysicalDeviceMultiviewFeaturesKHX *features =
(VkPhysicalDeviceMultiviewFeaturesKHX *)ext;
features->multiview = true;
features->multiviewGeometryShader = true;
features->multiviewTessellationShader = true;
break;
}
default: default:
anv_debug_ignored_stype(ext->sType); anv_debug_ignored_stype(ext->sType);
break; break;
@@ -789,6 +798,14 @@ void anv_GetPhysicalDeviceProperties2KHR(
break; break;
} }
case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_MULTIVIEW_PROPERTIES_KHX: {
VkPhysicalDeviceMultiviewPropertiesKHX *properties =
(VkPhysicalDeviceMultiviewPropertiesKHX *)ext;
properties->maxMultiviewViewCount = 16;
properties->maxMultiviewInstanceIndex = UINT32_MAX / 16;
break;
}
default: default:
anv_debug_ignored_stype(ext->sType); anv_debug_ignored_stype(ext->sType);
break; break;

View File

@@ -48,6 +48,7 @@ SUPPORTED_EXTENSIONS = [
'VK_KHX_external_memory', 'VK_KHX_external_memory',
'VK_KHX_external_memory_capabilities', 'VK_KHX_external_memory_capabilities',
'VK_KHX_external_memory_fd', 'VK_KHX_external_memory_fd',
'VK_KHX_multiview',
] ]
# We generate a static hash table for entry point lookup # We generate a static hash table for entry point lookup