From ec0dfb32b532fe2ddc28b3a1e65343e71cfcd92f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Quang=20Ng=C3=B4?= Date: Sun, 19 Jan 2025 19:03:15 +0700 Subject: [PATCH] Some ImGui tweaks for the game window (#2183) * Remove window border * Remove window rounding * Set background color to black --- src/video_core/renderer_vulkan/vk_presenter.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/video_core/renderer_vulkan/vk_presenter.cpp b/src/video_core/renderer_vulkan/vk_presenter.cpp index 36d64a5d5..35ab4318a 100644 --- a/src/video_core/renderer_vulkan/vk_presenter.cpp +++ b/src/video_core/renderer_vulkan/vk_presenter.cpp @@ -825,6 +825,9 @@ void Presenter::Present(Frame* frame, bool is_reusing_frame) { { // Draw the game ImGui::PushStyleVar(ImGuiStyleVar_WindowPadding, ImVec2{0.0f}); + ImGui::PushStyleVar(ImGuiStyleVar_WindowRounding, 0.0f); + ImGui::PushStyleVar(ImGuiStyleVar_WindowBorderSize, 0.0f); + ImGui::PushStyleColor(ImGuiCol_WindowBg, ImVec4(0.0f, 0.0f, 0.0f, 1.0f)); ImGui::SetNextWindowDockID(dockId, ImGuiCond_Once); ImGui::Begin("Display##game_display", nullptr, ImGuiWindowFlags_NoNav); @@ -840,7 +843,8 @@ void Presenter::Present(Frame* frame, bool is_reusing_frame) { static_cast(imgRect.extent.height), }); ImGui::End(); - ImGui::PopStyleVar(); + ImGui::PopStyleVar(3); + ImGui::PopStyleColor(); } ImGui::Core::Render(cmdbuf, swapchain_image_view, swapchain.GetExtent());