DEADSOFTWARE

less OpenGL calls for headless server
authorKetmar Dark <ketmar@ketmar.no-ip.org>
Wed, 13 Sep 2017 22:25:17 +0000 (01:25 +0300)
committerKetmar Dark <ketmar@ketmar.no-ip.org>
Wed, 13 Sep 2017 22:25:30 +0000 (01:25 +0300)
src/game/g_window.pas

index 71ec201bb1f9722cf39354213938eec54b9736d9..e137973ee1da9e6ac6b130479603c46c5ec7fd0a 100644 (file)
@@ -895,6 +895,12 @@ begin
 
   {EnumDisplayModes();}
 
+  {$IFDEF HEADLESS}
+  gwin_k8_enable_light_experiments = false;
+  gwin_has_stencil := false;
+  glLegacyNPOT := false;
+  gwin_dump_extensions := false;
+  {$ELSE}
   if gwin_k8_enable_light_experiments then
   begin
     SDL_GL_GetAttribute(SDL_GL_STENCIL_SIZE, @ltmp);
@@ -917,6 +923,7 @@ begin
     glLegacyNPOT := false;
   end;
   gwin_dump_extensions := false;
+  {$ENDIF}
 
   Init();
   Time_Old := GetTimer();