diff --git a/example/triangle.cpp b/example/triangle.cpp index abd26c0..1bdbe12 100644 --- a/example/triangle.cpp +++ b/example/triangle.cpp @@ -39,7 +39,7 @@ struct RenderData { }; int device_initialization (Init& init) { - init.window = create_window_glfw (false); + init.window = create_window_glfw ("Vulkan Triangle", false); vkb::InstanceBuilder instance_builder; auto instance_ret = instance_builder.use_default_debug_messenger ().request_validation_layers ().build (); diff --git a/tests/bootstrap_tests.cpp b/tests/bootstrap_tests.cpp index 38a3ee0..3e094ab 100644 --- a/tests/bootstrap_tests.cpp +++ b/tests/bootstrap_tests.cpp @@ -11,7 +11,7 @@ TEST_CASE ("Instance with surface", "[VkBootstrap.bootstrap]") { GIVEN ("A window and a vulkan instance") { - auto window = create_window_glfw (); + auto window = create_window_glfw ("Instance with surface"); vkb::InstanceBuilder instance_builder; auto instance_ret = instance_builder.use_default_debug_messenger ().build (); @@ -118,7 +118,7 @@ TEST_CASE ("Headless Vulkan", "[VkBootstrap.bootstrap]") { TEST_CASE ("Device Configuration", "[VkBootstrap.bootstrap]") { - auto window = create_window_glfw (); + auto window = create_window_glfw ("Device Configuration"); vkb::InstanceBuilder builder; auto instance_ret = builder.request_validation_layers ().build (); @@ -182,7 +182,7 @@ TEST_CASE ("Device Configuration", "[VkBootstrap.bootstrap]") { TEST_CASE ("Swapchain", "[VkBootstrap.bootstrap]") { GIVEN ("A working instance, window, surface, and device") { - auto window = create_window_glfw (); + auto window = create_window_glfw ("Swapchain"); vkb::InstanceBuilder builder; auto instance_ret = builder.request_validation_layers ().build (); @@ -274,7 +274,7 @@ TEST_CASE ("Allocation Callbacks", "[VkBootstrap.bootstrap]") { allocation_callbacks.pfnReallocation = &shim_vkReallocationFunction; allocation_callbacks.pfnFree = &shim_vkFreeFunction; - auto window = create_window_glfw (); + auto window = create_window_glfw ("Allocation Callbacks"); vkb::InstanceBuilder builder; auto instance_ret = diff --git a/tests/common.h b/tests/common.h index 3104501..6dfbba1 100644 --- a/tests/common.h +++ b/tests/common.h @@ -10,12 +10,12 @@ #include "../src/VkBootstrap.h" -GLFWwindow* create_window_glfw (bool resize = true) { +GLFWwindow* create_window_glfw (const char * window_name = "", bool resize = true) { glfwInit (); glfwWindowHint (GLFW_CLIENT_API, GLFW_NO_API); if (!resize) glfwWindowHint (GLFW_RESIZABLE, GLFW_FALSE); - return glfwCreateWindow (640, 480, "Vulkan Triangle", NULL, NULL); + return glfwCreateWindow (640, 480, window_name, NULL, NULL); } void destroy_window_glfw (GLFWwindow* window) { glfwDestroyWindow (window);