# HG changeset patch # User Michael Pavone # Date 1541784367 28800 # Node ID 9b7cba9ba541e7bb9585218abfb97d6c9ab961ab # Parent cc699c4966b1369ac0dd1b8e616936c39c05cd95 Use SDL_GL_MakeCurrent to make the SDL renderer API windows play nice with GL windows diff -r cc699c4966b1 -r 9b7cba9ba541 render_sdl.c --- a/render_sdl.c Mon Nov 05 00:30:44 2018 -0800 +++ b/render_sdl.c Fri Nov 09 09:26:07 2018 -0800 @@ -1442,6 +1442,7 @@ width -= overscan_left[video_standard] + overscan_right[video_standard]; #ifndef DISABLE_OPENGL if (render_gl && which <= FRAMEBUFFER_EVEN) { + SDL_GL_MakeCurrent(main_window, main_context); glBindTexture(GL_TEXTURE_2D, textures[which]); glTexSubImage2D(GL_TEXTURE_2D, 0, 0, 0, LINEBUF_SIZE, height, GL_BGRA, GL_UNSIGNED_BYTE, texture_buf + overscan_left[video_standard] + LINEBUF_SIZE * overscan_top[video_standard]);