mirror of
https://git.code.sf.net/p/quake/quakeforge
synced 2024-11-22 20:41:20 +00:00
Output validation message severity
It's nice knowing if something is an error or otherwise.
This commit is contained in:
parent
c0bc5cfad6
commit
b5828bc2ce
1 changed files with 14 additions and 1 deletions
|
@ -219,7 +219,20 @@ debug_callback (VkDebugUtilsMessageSeverityFlagBitsEXT messageSeverity,
|
||||||
const VkDebugUtilsMessengerCallbackDataEXT* callbackData,
|
const VkDebugUtilsMessengerCallbackDataEXT* callbackData,
|
||||||
void *data)
|
void *data)
|
||||||
{
|
{
|
||||||
fprintf (stderr, "validation layer: %s\n", callbackData->pMessage);
|
const char *msgSev = "";
|
||||||
|
if (messageSeverity & VK_DEBUG_UTILS_MESSAGE_SEVERITY_VERBOSE_BIT_EXT) {
|
||||||
|
msgSev = "verbose: ";
|
||||||
|
}
|
||||||
|
if (messageSeverity & VK_DEBUG_UTILS_MESSAGE_SEVERITY_INFO_BIT_EXT) {
|
||||||
|
msgSev = "info: ";
|
||||||
|
}
|
||||||
|
if (messageSeverity & VK_DEBUG_UTILS_MESSAGE_SEVERITY_WARNING_BIT_EXT) {
|
||||||
|
msgSev = "warning: ";
|
||||||
|
}
|
||||||
|
if (messageSeverity & VK_DEBUG_UTILS_MESSAGE_SEVERITY_ERROR_BIT_EXT) {
|
||||||
|
msgSev = "error: ";
|
||||||
|
}
|
||||||
|
fprintf (stderr, "validation layer: %s%s\n", msgSev, callbackData->pMessage);
|
||||||
return VK_FALSE;
|
return VK_FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue