From fdc57ce7b8c77f074381d0f04030976b291b7a1e Mon Sep 17 00:00:00 2001 From: Gary Talent Date: Sun, 10 Jul 2022 15:48:14 -0500 Subject: [PATCH] [nostalgia/core/studio] Fix cast of 32 bit int to pointer --- src/nostalgia/core/studio/tilesheeteditor-imgui.cpp | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/src/nostalgia/core/studio/tilesheeteditor-imgui.cpp b/src/nostalgia/core/studio/tilesheeteditor-imgui.cpp index 04444404..a5fae3a5 100644 --- a/src/nostalgia/core/studio/tilesheeteditor-imgui.cpp +++ b/src/nostalgia/core/studio/tilesheeteditor-imgui.cpp @@ -276,11 +276,12 @@ void TileSheetEditorImGui::drawTileSheet(const geo::Vec2 &fbSize) noexcept { glViewport(0, 0, fbSizei.width, fbSizei.height); m_tileSheetEditor.draw(); glBindFramebuffer(GL_FRAMEBUFFER, 0); + uintptr_t buffId = m_framebuffer.color.id; ImGui::Image( - reinterpret_cast(m_framebuffer.color.id), - static_cast(fbSize), - ImVec2(0, 1), - ImVec2(1, 0)); + reinterpret_cast(buffId), + static_cast(fbSize), + ImVec2(0, 1), + ImVec2(1, 0)); // handle input, this must come after drawing const auto &io = ImGui::GetIO(); const auto mousePos = geo::Vec2(io.MousePos);