mirror of
https://github.com/Relintai/sdl2_frt.git
synced 2024-12-16 11:06:49 +01:00
Merge commit 'e14fb54e3f409aaf1e10b94f681677c59b1b7e0d' into main
This commit is contained in:
commit
f5253b708d
@ -838,28 +838,6 @@ SDL_CreateRenderer(SDL_Window * window, int index, Uint32 flags)
|
||||
}
|
||||
}
|
||||
|
||||
#if SDL_VIDEO_DRIVER_KMSDRM
|
||||
|
||||
/* Even if full OpenGL works with the KMSDRM backend, GLES2 renderer is still preferred. */
|
||||
if ((SDL_strcmp(SDL_GetCurrentVideoDriver(), "KMSDRM") == 0) && (!renderer)) {
|
||||
|
||||
for (index = 0; index < n; ++index) {
|
||||
|
||||
const SDL_RenderDriver *driver = render_drivers[index];
|
||||
|
||||
if ((SDL_strcmp(driver->info.name, "opengles2") == 0) && (!renderer)) {
|
||||
/* Create a new renderer instance */
|
||||
renderer = driver->CreateRenderer(window, flags);
|
||||
if (renderer) {
|
||||
/* Got an OpenGL_ES2 renderer as expected for KMSDRM by default. */
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
if (!renderer) {
|
||||
for (index = 0; index < n; ++index) {
|
||||
const SDL_RenderDriver *driver = render_drivers[index];
|
||||
|
Loading…
Reference in New Issue
Block a user