Skip to content

Commit f0245f3

Browse files
authored
update imgui to v1.91.9b (#338)
1 parent f9a7607 commit f0245f3

File tree

6 files changed

+9
-7
lines changed

6 files changed

+9
-7
lines changed

deps/imgui/imgui

Submodule imgui updated 139 files

src/color_image_quantity.cpp

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -107,9 +107,10 @@ void ColorImageQuantity::showInImGuiWindow() {
107107

108108
// since we are showing directly from the user's texture, we need to resposect the upper left ordering
109109
if (imageOrigin == ImageOrigin::LowerLeft) {
110-
ImGui::Image(colors.getRenderTextureBuffer()->getNativeHandle(), ImVec2(w, h), ImVec2(0, 1), ImVec2(1, 0));
110+
ImGui::Image((ImTextureID)(intptr_t)colors.getRenderTextureBuffer()->getNativeHandle(), ImVec2(w, h), ImVec2(0, 1),
111+
ImVec2(1, 0));
111112
} else if (imageOrigin == ImageOrigin::UpperLeft) {
112-
ImGui::Image(colors.getRenderTextureBuffer()->getNativeHandle(), ImVec2(w, h));
113+
ImGui::Image((ImTextureID)(intptr_t)colors.getRenderTextureBuffer()->getNativeHandle(), ImVec2(w, h));
113114
}
114115
render::engine->preserveResourceUntilImguiFrameCompletes(colors.getRenderTextureBuffer());
115116

src/histogram.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -201,7 +201,7 @@ void Histogram::buildUI(float width) {
201201
float h = w / aspect;
202202

203203
// Render image
204-
ImGui::Image(texture->getNativeHandle(), ImVec2(w, h), ImVec2(0, 1), ImVec2(1, 0));
204+
ImGui::Image((ImTextureID)(intptr_t)texture->getNativeHandle(), ImVec2(w, h), ImVec2(0, 1), ImVec2(1, 0));
205205
render::engine->preserveResourceUntilImguiFrameCompletes(texture);
206206

207207
// Helpful info for drawing annotations below

src/imgui_config.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ void configureImGuiStyle() {
6868
colors[ImGuiCol_DragDropTarget] = ImVec4(1.00f, 1.00f, 0.00f, 0.90f);
6969
colors[ImGuiCol_Tab] = ImVec4(0.27f, 0.54f, 0.42f, 0.83f);
7070
colors[ImGuiCol_TabHovered] = ImVec4(0.34f, 0.68f, 0.53f, 0.83f);
71-
colors[ImGuiCol_TabActive] = ImVec4(0.38f, 0.76f, 0.58f, 0.83f);
71+
colors[ImGuiCol_TabSelected] = ImVec4(0.38f, 0.76f, 0.58f, 0.83f);
7272
}
7373

7474

src/render/engine.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1176,7 +1176,7 @@ void Engine::showTextureInImGuiWindow(std::string windowName, TextureBuffer* buf
11761176
float h = w * buffer->getSizeY() / buffer->getSizeX();
11771177

11781178
ImGui::Text("Dimensions: %dx%d", buffer->getSizeX(), buffer->getSizeY());
1179-
ImGui::Image(buffer->getNativeHandle(), ImVec2(w, h), ImVec2(0, 1), ImVec2(1, 0));
1179+
ImGui::Image((ImTextureID)(intptr_t)buffer->getNativeHandle(), ImVec2(w, h), ImVec2(0, 1), ImVec2(1, 0));
11801180

11811181
ImGui::End();
11821182
}

src/scalar_image_quantity.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,8 @@ void ScalarImageQuantity::showInImGuiWindow() {
114114

115115
// here we always use the same ImVec2 UV coords below, because the texture order is always openGL convention after the
116116
// intermediate render pass
117-
ImGui::Image(textureIntermediateRendered->getNativeHandle(), ImVec2(w, h), ImVec2(0, 1), ImVec2(1, 0));
117+
ImGui::Image((ImTextureID)(intptr_t)textureIntermediateRendered->getNativeHandle(), ImVec2(w, h), ImVec2(0, 1),
118+
ImVec2(1, 0));
118119
render::engine->preserveResourceUntilImguiFrameCompletes(textureIntermediateRendered);
119120

120121

0 commit comments

Comments
 (0)