Enable the precise occlusion query feature

This commit is contained in:
xddxd 2021-09-16 12:17:35 +03:00 committed by kd-11
parent 56e982375e
commit d511e76a63
1 changed files with 11 additions and 0 deletions

View File

@ -332,6 +332,11 @@ namespace vk
enabled_features.shaderStorageImageWriteWithoutFormat = VK_TRUE;
}
if (g_cfg.video.precise_zpass_count)
{
enabled_features.occlusionQueryPrecise = VK_TRUE;
}
// enabled_features.shaderSampledImageArrayDynamicIndexing = TRUE; // Unused currently but will be needed soon
enabled_features.shaderClipDistance = VK_TRUE;
// enabled_features.shaderCullDistance = VK_TRUE; // Alt notation of clip distance
@ -406,6 +411,12 @@ namespace vk
enabled_features.alphaToOne = VK_FALSE;
}
if (!pgpu->features.occlusionQueryPrecise && enabled_features.occlusionQueryPrecise)
{
rsx_log.error("Your GPU does not support precise occlusion queries. Graphics may not render correctly.");
enabled_features.occlusionQueryPrecise = VK_FALSE;
}
VkDeviceCreateInfo device = {};
device.sType = VK_STRUCTURE_TYPE_DEVICE_CREATE_INFO;
device.pNext = nullptr;