Skip to content

Commit

Permalink
Merge branch 'master' into docking
Browse files Browse the repository at this point in the history
# Conflicts:
#	backends/imgui_impl_win32.cpp
#	examples/example_marmalade/main.cpp
#	imgui.cpp
#	imgui.h
  • Loading branch information
ocornut committed Dec 22, 2021
2 parents 06d5f92 + 512c54b commit 15b4a06
Show file tree
Hide file tree
Showing 19 changed files with 54 additions and 581 deletions.
1 change: 1 addition & 0 deletions backends/imgui_impl_glfw.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -300,6 +300,7 @@ static bool ImGui_ImplGlfw_Init(GLFWwindow* window, bool install_callbacks, Glfw

// Chain GLFW callbacks: our callbacks will call the user's previously installed callbacks, if any.
bd->PrevUserCallbackWindowFocus = NULL;
bd->PrevUserCallbackCursorEnter = NULL;
bd->PrevUserCallbackMousebutton = NULL;
bd->PrevUserCallbackScroll = NULL;
bd->PrevUserCallbackKey = NULL;
Expand Down
318 changes: 0 additions & 318 deletions backends/imgui_impl_marmalade.cpp

This file was deleted.

28 changes: 0 additions & 28 deletions backends/imgui_impl_marmalade.h

This file was deleted.

7 changes: 6 additions & 1 deletion backends/imgui_impl_sdlrenderer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
// Read online: https://github.com/ocornut/imgui/tree/master/docs

// CHANGELOG
// 2021-12-21: Update SDL_RenderGeometryRaw() format to work with SDL 2.0.19.
// 2021-12-03: Added support for large mesh (64K+ vertices), enable ImGuiBackendFlags_RendererHasVtxOffset flag.
// 2021-10-06: Backup and restore modified ClipRect/Viewport.
// 2021-09-21: Initial version.
Expand Down Expand Up @@ -175,7 +176,11 @@ void ImGui_ImplSDLRenderer_RenderDrawData(ImDrawData* draw_data)

const float* xy = (const float*)((const char*)(vtx_buffer + pcmd->VtxOffset) + IM_OFFSETOF(ImDrawVert, pos));
const float* uv = (const float*)((const char*)(vtx_buffer + pcmd->VtxOffset) + IM_OFFSETOF(ImDrawVert, uv));
const int* color = (const int*)((const char*)(vtx_buffer + pcmd->VtxOffset) + IM_OFFSETOF(ImDrawVert, col));
#if SDL_VERSION_ATLEAST(2,0,19)
const SDL_Color* color = (const SDL_Color*)((const char*)(vtx_buffer + pcmd->VtxOffset) + IM_OFFSETOF(ImDrawVert, col)); // SDL 2.0.19+
#else
const int* color = (const int*)((const char*)(vtx_buffer + pcmd->VtxOffset) + IM_OFFSETOF(ImDrawVert, col)); // SDL 2.0.17 and 2.0.18
#endif

// Bind texture, Draw
SDL_Texture* tex = (SDL_Texture*)pcmd->GetTexID();
Expand Down
Loading

0 comments on commit 15b4a06

Please sign in to comment.