weh
This commit is contained in:
parent
ea7f6d3e1e
commit
80d31eafef
10
src/main.cpp
10
src/main.cpp
|
@ -9,7 +9,8 @@
|
|||
#include <span>
|
||||
#include <stdexcept>
|
||||
|
||||
#include "src/util/types.h"
|
||||
#include "util/magic_enum.hpp"
|
||||
#include "util/types.h"
|
||||
|
||||
const uint32_t WIDTH = 800;
|
||||
const uint32_t HEIGHT = 600;
|
||||
|
@ -183,8 +184,11 @@ class Application {
|
|||
}
|
||||
|
||||
fn createSurface() -> void {
|
||||
if (glfwCreateWindowSurface(mInstance, mWindow, nullptr, &mSurface) != VK_SUCCESS)
|
||||
throw std::runtime_error("failed to create window surface!");
|
||||
if (VkResult result = glfwCreateWindowSurface(mInstance, mWindow, nullptr, &mSurface);
|
||||
result != VK_SUCCESS)
|
||||
throw std::runtime_error(
|
||||
"Failed to create window surface! Error: " + string(magic_enum::enum_name(result))
|
||||
);
|
||||
}
|
||||
|
||||
fn pickPhysicalDevice() -> void {
|
||||
|
|
Loading…
Reference in a new issue