Browse Source

Backends: SDL3: Update for introduction of SDL_GLContext from void*. (#7701, #7702)

pull/7740/head
bcsanches 5 months ago
committed by ocornut
parent
commit
64a82d73c9
  1. 3
      backends/imgui_impl_sdl3.cpp
  2. 9
      docs/CHANGELOG.txt

3
backends/imgui_impl_sdl3.cpp

@ -502,6 +502,7 @@ static bool ImGui_ImplSDL3_Init(SDL_Window* window, SDL_Renderer* renderer, void
return true;
}
// Should technically be a SDL_GLContext but due to typedef it is sane to keep it void* in public interface.
bool ImGui_ImplSDL3_InitForOpenGL(SDL_Window* window, void* sdl_gl_context)
{
return ImGui_ImplSDL3_Init(window, nullptr, sdl_gl_context);
@ -1053,7 +1054,7 @@ static void ImGui_ImplSDL3_InitPlatformInterface(SDL_Window* window, void* sdl_g
vd->Window = window;
vd->WindowID = SDL_GetWindowID(window);
vd->WindowOwned = false;
vd->GLContext = sdl_gl_context;
vd->GLContext = (SDL_GLContext)sdl_gl_context;
main_viewport->PlatformUserData = vd;
main_viewport->PlatformHandle = vd->Window;
}

9
docs/CHANGELOG.txt

@ -35,6 +35,15 @@ HOW TO UPDATE?
and API updates have been a little more frequent lately. They are documented below and in imgui.cpp and should not affect all users.
- Please report any issue!
-----------------------------------------------------------------------
VERSION 1.90.9 WIP (In Progress)
-----------------------------------------------------------------------
Other changes:
- Backends: SDL3: Update for introduction of SDL_GLContext from void*. (#7701, #7702)
[@bcsanches]
-----------------------------------------------------------------------
VERSION 1.90.8 (Released 2024-06-06)
-----------------------------------------------------------------------

Loading…
Cancel
Save