From 2f2567044a63b23cfae8abe00458d6dc97aea1f5 Mon Sep 17 00:00:00 2001 From: Brandon Mak Date: Fri, 16 Sep 2022 17:28:27 +0800 Subject: [PATCH] Submitted command buffer :D --- SHADE_Application/src/Application/SBApplication.cpp | 2 +- SHADE_Engine/src/Editor/SHEditor.cpp | 7 +++++++ 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/SHADE_Application/src/Application/SBApplication.cpp b/SHADE_Application/src/Application/SBApplication.cpp index 279ee81e..4216ba03 100644 --- a/SHADE_Application/src/Application/SBApplication.cpp +++ b/SHADE_Application/src/Application/SBApplication.cpp @@ -33,7 +33,7 @@ namespace Sandbox // Set working directory SHADE::SHFileUtilities::SetWorkDirToExecDir(); - SDL_Init(SDL_INIT_VIDEO); + SDL_Init(SDL_INIT_EVERYTHING); window.Create(hInstance, hPrevInstance, lpCmdLine, nCmdShow); SHADE::SHSystemManager::CreateSystem(); SHADE::SHGraphicsSystem* graphicsSystem = static_cast(SHADE::SHSystemManager::GetSystem()); diff --git a/SHADE_Engine/src/Editor/SHEditor.cpp b/SHADE_Engine/src/Editor/SHEditor.cpp index 91fc750b..6d0f1a28 100644 --- a/SHADE_Engine/src/Editor/SHEditor.cpp +++ b/SHADE_Engine/src/Editor/SHEditor.cpp @@ -49,6 +49,7 @@ namespace SHADE imguiCommandBuffer->BeginRecording(); ImGui_ImplVulkan_CreateFontsTexture(imguiCommandBuffer->GetVkCommandBuffer()); imguiCommandBuffer->EndRecording(); + gfxSystem->GetQueue()->SubmitCommandBuffer({imguiCommandBuffer}, {}, {}, vk::PipelineStageFlagBits::eNone, {}); ImGui_ImplVulkan_DestroyFontUploadObjects(); @@ -67,6 +68,12 @@ namespace SHADE NewFrame(); ImGui::ShowDemoWindow(); + ImGui::Begin("Your mom"); + if (ImGui::Button("OP")) + { + std::cout << "HEHEHEOHEIOHIEOH\n"; + } + ImGui::End(); } void SHEditor::Render()