changeset 2493:b62336ceb626 default tip

Kinda hacky fix to make sure Nuklear has the right GL context
author Michael Pavone <pavone@retrodev.com>
date Wed, 17 Apr 2024 22:18:45 -0700
parents 88210caedc53
children
files render_sdl.c
diffstat 1 files changed, 5 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/render_sdl.c	Wed Apr 17 22:14:37 2024 -0700
+++ b/render_sdl.c	Wed Apr 17 22:18:45 2024 -0700
@@ -1402,6 +1402,11 @@
 
 SDL_Window *render_get_window(void)
 {
+#ifndef DISABLE_OPENGL
+	if (render_gl) {
+		SDL_GL_MakeCurrent(main_window, main_context);
+	}
+#endif
 	return main_window;
 }