X-Git-Url: https://deadsoftware.ru/gitweb?a=blobdiff_plain;f=src%2Fgame%2Fsdl%2Fg_system.pas;h=cc8704c9713e76700e0da37c4cdc14c45f9d3d2f;hb=e84299fd3f1bf3f58e7aeddc017d2b6dc835f676;hp=0fcad1aec0afa596a05959c9388e5de33f7ff502;hpb=b1e7f99d9eea1711acf7471e9827500acccc5820;p=d2df-sdl.git diff --git a/src/game/sdl/g_system.pas b/src/game/sdl/g_system.pas index 0fcad1a..cc8704c 100644 --- a/src/game/sdl/g_system.pas +++ b/src/game/sdl/g_system.pas @@ -78,12 +78,22 @@ implementation (* --------- Graphics --------- *) function LoadGL: Boolean; + {$IFNDEF NOGL_INIT} + var + ltmp: Integer; + {$ENDIF} begin result := true; {$IFDEF NOGL_INIT} nogl_Init; if glRenderToFBO and (not nogl_ExtensionSupported('GL_OES_framebuffer_object')) then {$ELSE} + if SDL_GL_GetAttribute(SDL_GL_STENCIL_SIZE, @ltmp) = 0 then + begin + e_LogWritefln('stencil buffer size: %s', [ltmp]); + gwin_has_stencil := (ltmp > 0); + end; + if glRenderToFBO and (not Load_GL_ARB_framebuffer_object) then {$ENDIF} begin