mirror of
https://github.com/Drezil/imgui.git
synced 2025-07-04 20:18:47 +02:00
Examples: Updated for reorganized context functions. Calling CreateContext(), DestroyContext() in example code. Removed Shutdown() from binding code. (#1565, #586, #992, #1007, #1558)
This commit is contained in:
@ -787,7 +787,6 @@ bool ImGui_ImplGlfwVulkan_Init(GLFWwindow* window, bool install_callbacks, Im
|
||||
void ImGui_ImplGlfwVulkan_Shutdown()
|
||||
{
|
||||
ImGui_ImplGlfwVulkan_InvalidateDeviceObjects();
|
||||
ImGui::Shutdown();
|
||||
}
|
||||
|
||||
void ImGui_ImplGlfwVulkan_NewFrame()
|
||||
|
@ -615,6 +615,7 @@ int main(int, char**)
|
||||
setup_vulkan(window);
|
||||
|
||||
// Setup ImGui binding
|
||||
ImGui::CreateContext();
|
||||
ImGui_ImplGlfwVulkan_Init_Data init_data = {};
|
||||
init_data.allocator = g_Allocator;
|
||||
init_data.gpu = g_Gpu;
|
||||
@ -737,6 +738,7 @@ int main(int, char**)
|
||||
VkResult err = vkDeviceWaitIdle(g_Device);
|
||||
check_vk_result(err);
|
||||
ImGui_ImplGlfwVulkan_Shutdown();
|
||||
ImGui::DestroyContext();
|
||||
cleanup_vulkan();
|
||||
glfwTerminate();
|
||||
|
||||
|
Reference in New Issue
Block a user