From 14771a7395dda16d199b88c71d975d840c7e5b14 Mon Sep 17 00:00:00 2001 From: fgsfds Date: Tue, 18 Feb 2020 23:35:53 +0300 Subject: [PATCH] always try to load FBO extensions in case user enables r_fbo later --- src/game/sdl/g_system.pas | 4 ++-- src/game/sdl2/g_system.pas | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/game/sdl/g_system.pas b/src/game/sdl/g_system.pas index bba2cae..a4cbe64 100644 --- a/src/game/sdl/g_system.pas +++ b/src/game/sdl/g_system.pas @@ -127,9 +127,9 @@ implementation begin {$IFDEF NOGL_INIT} nogl_Init; - if glRenderToFBO and (not nogl_ExtensionSupported('GL_OES_framebuffer_object')) then + if (not nogl_ExtensionSupported('GL_OES_framebuffer_object')) and glRenderToFBO then {$ELSE} - if glRenderToFBO and (not Load_GL_ARB_framebuffer_object()) then + if (not Load_GL_ARB_framebuffer_object()) and glRenderToFBO then {$ENDIF} begin e_LogWriteln('SDL: no framebuffer object support detected'); diff --git a/src/game/sdl2/g_system.pas b/src/game/sdl2/g_system.pas index 29a81b0..e4bd070 100644 --- a/src/game/sdl2/g_system.pas +++ b/src/game/sdl2/g_system.pas @@ -158,9 +158,9 @@ implementation begin {$IFDEF NOGL_INIT} nogl_Init; - if glRenderToFBO and (not nogl_ExtensionSupported('GL_OES_framebuffer_object')) then + if (not nogl_ExtensionSupported('GL_OES_framebuffer_object')) and glRenderToFBO then {$ELSE} - if glRenderToFBO and (not Load_GL_ARB_framebuffer_object()) then + if (not Load_GL_ARB_framebuffer_object()) and glRenderToFBO then {$ENDIF} begin e_LogWriteln('SDL: no framebuffer object support detected'); -- 2.29.2