diff --git a/src/client/refresh/vk/vk_common.c b/src/client/refresh/vk/vk_common.c index 17ec2899..4d7668de 100644 --- a/src/client/refresh/vk/vk_common.c +++ b/src/client/refresh/vk/vk_common.c @@ -1645,6 +1645,25 @@ qboolean QVk_Init(SDL_Window *window) .ppEnabledExtensionNames = (const char* const*)wantedExtensions }; +// introduced in SDK 1.1.121 +#if VK_HEADER_VERSION > 114 + VkValidationFeatureEnableEXT validationFeaturesEnable[] = { VK_VALIDATION_FEATURE_ENABLE_BEST_PRACTICES_EXT }; + VkValidationFeaturesEXT validationFeatures = { + .sType = VK_STRUCTURE_TYPE_VALIDATION_FEATURES_EXT, + .pNext = NULL, + .enabledValidationFeatureCount = sizeof(validationFeaturesEnable) / sizeof(validationFeaturesEnable[0]), + .pEnabledValidationFeatures = validationFeaturesEnable, + .disabledValidationFeatureCount = 0, + .pDisabledValidationFeatures = NULL + }; + + if (vk_validation->value > 1) + { + createInfo.pNext = &validationFeatures; + } +#endif + +// introduced in SDK 1.1.106 #if VK_HEADER_VERSION > 101 const char *validationLayers[] = { "VK_LAYER_KHRONOS_validation" }; #else diff --git a/src/client/refresh/vk/vk_validation.c b/src/client/refresh/vk/vk_validation.c index 00e7436e..2710ba84 100644 --- a/src/client/refresh/vk/vk_validation.c +++ b/src/client/refresh/vk/vk_validation.c @@ -53,7 +53,6 @@ static VKAPI_ATTR VkBool32 VKAPI_CALL debugUtilsCallback(VkDebugUtilsMessageSeve break; case VK_DEBUG_UTILS_MESSAGE_SEVERITY_WARNING_BIT_EXT: R_Printf(PRINT_ALL, "VK_WARNING: %s %s\n", callbackData->pMessage, msgToString(msgType)); - assert(!"Vulkan warning occured!"); break; default: R_Printf(PRINT_ALL, "VK_ERROR: %s %s\n", callbackData->pMessage, msgToString(msgType));