Skip to content

Commit

Permalink
Updated to latest upstream imgui, refactorings for a few breaking cha…
Browse files Browse the repository at this point in the history
…nges
  • Loading branch information
azonenberg committed Oct 22, 2024
1 parent 57332a0 commit 5e6c3ac
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 8 deletions.
2 changes: 1 addition & 1 deletion src/imgui
Submodule imgui updated 57 files
+53 −4 .github/workflows/build.yml
+16 −15 backends/imgui_impl_allegro5.cpp
+74 −73 backends/imgui_impl_dx10.cpp
+91 −80 backends/imgui_impl_dx11.cpp
+12 −0 backends/imgui_impl_dx11.h
+44 −46 backends/imgui_impl_dx12.cpp
+11 −5 backends/imgui_impl_dx12.h
+86 −78 backends/imgui_impl_dx9.cpp
+46 −13 backends/imgui_impl_glfw.cpp
+16 −17 backends/imgui_impl_metal.mm
+15 −13 backends/imgui_impl_opengl2.cpp
+19 −17 backends/imgui_impl_opengl3.cpp
+6 −0 backends/imgui_impl_opengl3_loader.h
+9 −8 backends/imgui_impl_osx.mm
+23 −13 backends/imgui_impl_sdl2.cpp
+60 −26 backends/imgui_impl_sdl3.cpp
+1 −2 backends/imgui_impl_sdl3.h
+19 −8 backends/imgui_impl_sdlrenderer2.cpp
+9 −0 backends/imgui_impl_sdlrenderer2.h
+23 −10 backends/imgui_impl_sdlrenderer3.cpp
+11 −0 backends/imgui_impl_sdlrenderer3.h
+38 −34 backends/imgui_impl_vulkan.cpp
+21 −13 backends/imgui_impl_vulkan.h
+58 −16 backends/imgui_impl_wgpu.cpp
+17 −0 backends/imgui_impl_wgpu.h
+52 −32 backends/imgui_impl_win32.cpp
+1 −1 docs/BACKENDS.md
+271 −23 docs/CHANGELOG.txt
+28 −26 docs/FAQ.md
+5 −1 docs/FONTS.md
+4 −4 docs/README.md
+4 −7 docs/TODO.txt
+1 −1 examples/example_glfw_vulkan/CMakeLists.txt
+2 −2 examples/example_glfw_vulkan/build_win32.bat
+2 −2 examples/example_glfw_vulkan/build_win64.bat
+4 −4 examples/example_glfw_vulkan/example_glfw_vulkan.vcxproj
+5 −1 examples/example_glfw_wgpu/CMakeLists.txt
+1 −1 examples/example_null/Makefile
+1 −1 examples/example_sdl2_vulkan/build_win32.bat
+5 −5 examples/example_sdl2_vulkan/example_sdl2_vulkan.vcxproj
+1 −1 examples/example_sdl3_opengl3/main.cpp
+1 −1 examples/example_sdl3_sdlrenderer3/main.cpp
+1 −2 examples/example_win32_directx12/build_win32.bat
+5 −5 examples/example_win32_directx12/example_win32_directx12.vcxproj
+0 −4 examples/example_win32_directx12/main.cpp
+6 −3 imconfig.h
+851 −292 imgui.cpp
+114 −54 imgui.h
+87 −16 imgui_demo.cpp
+35 −8 imgui_draw.cpp
+170 −338 imgui_internal.h
+28 −24 imgui_tables.cpp
+459 −326 imgui_widgets.cpp
+63 −35 imstb_textedit.h
+22 −4 misc/freetype/README.md
+19 −5 misc/freetype/imgui_freetype.cpp
+7 −0 misc/freetype/imgui_freetype.h
12 changes: 7 additions & 5 deletions src/ngscopeclient/TextureManager.cpp
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
/***********************************************************************************************************************
* *
* glscopeclient *
* ngscopeclient *
* *
* Copyright (c) 2012-2022 Andrew D. Zonenberg *
* Copyright (c) 2012-2024 Andrew D. Zonenberg *
* All rights reserved. *
* *
* Redistribution and use in source and binary forms, with or without modification, are permitted provided that the *
Expand Down Expand Up @@ -124,7 +124,8 @@ Texture::Texture(
);
m_view = make_unique<vk::raii::ImageView>(*g_vkComputeDevice, vinfo);

m_texture = ImGui_ImplVulkan_AddTexture(**mgr->GetSampler(), **m_view, VK_IMAGE_LAYOUT_SHADER_READ_ONLY_OPTIMAL);
m_texture = reinterpret_cast<intptr_t>(
ImGui_ImplVulkan_AddTexture(**mgr->GetSampler(), **m_view, VK_IMAGE_LAYOUT_SHADER_READ_ONLY_OPTIMAL));

SetName(name);
}
Expand Down Expand Up @@ -177,7 +178,8 @@ Texture::Texture(
);
m_view = make_unique<vk::raii::ImageView>(*g_vkComputeDevice, vinfo);

m_texture = ImGui_ImplVulkan_AddTexture(**mgr->GetSampler(), **m_view, VK_IMAGE_LAYOUT_GENERAL);
m_texture = reinterpret_cast<intptr_t>(
ImGui_ImplVulkan_AddTexture(**mgr->GetSampler(), **m_view, VK_IMAGE_LAYOUT_GENERAL));

SetName(name);
}
Expand All @@ -199,7 +201,7 @@ void Texture::SetName(const string& name)
g_vkComputeDevice->setDebugUtilsObjectNameEXT(
vk::DebugUtilsObjectNameInfoEXT(
vk::ObjectType::eDescriptorSet,
reinterpret_cast<uint64_t>(m_texture),
m_texture,
texName.c_str()));

g_vkComputeDevice->setDebugUtilsObjectNameEXT(
Expand Down
2 changes: 1 addition & 1 deletion src/ngscopeclient/WaveformArea.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2375,7 +2375,7 @@ void WaveformArea::RenderYAxis(ImVec2 size, map<float, float>& gridmap, float vb
ImGui::Dummy(size);

//Catch mouse wheel events
ImGui::SetItemUsingMouseWheel();
ImGui::SetItemKeyOwner(ImGuiKey_MouseWheelY);
if(ImGui::IsItemHovered())
{
auto wheel = ImGui::GetIO().MouseWheel;
Expand Down
2 changes: 1 addition & 1 deletion src/ngscopeclient/WaveformGroup.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -860,7 +860,7 @@ void WaveformGroup::RenderTimeline(float width, float height)
if( (mouseDelta.x != 0) || (mouseDelta.y != 0) )
m_tLastMouseMove = tnow;

ImGui::SetItemUsingMouseWheel();
ImGui::SetItemKeyOwner(ImGuiKey_MouseWheelY);
if(ImGui::IsItemHovered())
{
//Catch mouse wheel events
Expand Down

0 comments on commit 5e6c3ac

Please sign in to comment.