i prefer this
This commit is contained in:
parent
d6c93896d1
commit
651f339537
22
src/main.cpp
22
src/main.cpp
|
@ -57,19 +57,15 @@ class HelloTriangleApplication {
|
|||
if (!enableValidationLayers)
|
||||
return;
|
||||
|
||||
auto messengerCreateInfo = vk::DebugUtilsMessengerCreateInfoEXT()
|
||||
.setMessageSeverity(
|
||||
vk::DebugUtilsMessageSeverityFlagBitsEXT::eVerbose |
|
||||
vk::DebugUtilsMessageSeverityFlagBitsEXT::eWarning |
|
||||
vk::DebugUtilsMessageSeverityFlagBitsEXT::eError
|
||||
)
|
||||
.setMessageType(
|
||||
vk::DebugUtilsMessageTypeFlagBitsEXT::eGeneral |
|
||||
vk::DebugUtilsMessageTypeFlagBitsEXT::ePerformance |
|
||||
vk::DebugUtilsMessageTypeFlagBitsEXT::eValidation
|
||||
)
|
||||
.setPfnUserCallback(debugCallback)
|
||||
.setPUserData(nullptr); // Optional
|
||||
vk::DebugUtilsMessengerCreateInfoEXT messengerCreateInfo {
|
||||
.messageSeverity = vk::DebugUtilsMessageSeverityFlagBitsEXT::eVerbose |
|
||||
vk::DebugUtilsMessageSeverityFlagBitsEXT::eWarning |
|
||||
vk::DebugUtilsMessageSeverityFlagBitsEXT::eError,
|
||||
.messageType = vk::DebugUtilsMessageTypeFlagBitsEXT::eGeneral |
|
||||
vk::DebugUtilsMessageTypeFlagBitsEXT::eValidation |
|
||||
vk::DebugUtilsMessageTypeFlagBitsEXT::ePerformance,
|
||||
.pfnUserCallback = debugCallback,
|
||||
};
|
||||
|
||||
mDebugMessenger = mInstance->createDebugUtilsMessengerEXTUnique(messengerCreateInfo, nullptr, mLoader);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue