X-Git-Url: http://deadsoftware.ru/gitweb?a=blobdiff_plain;f=src%2Fengine%2Fe_graphics.pas;h=ca6dcf17bcbbb5565476c63f14b30e8fe3c8f2a2;hb=ff17260e083bdf4461154b916a716cd9b61126b1;hp=b1d34101d44014c5ab06d3aa6b96dcfc32d94863;hpb=a49e32f2040ac79644fabdfa629cd4fd4750c515;p=d2df-sdl.git diff --git a/src/engine/e_graphics.pas b/src/engine/e_graphics.pas index b1d3410..ca6dcf1 100644 --- a/src/engine/e_graphics.pas +++ b/src/engine/e_graphics.pas @@ -2,8 +2,7 @@ * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. + * the Free Software Foundation, version 3 of the License ONLY. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of @@ -20,7 +19,11 @@ interface uses {$INCLUDE ../nogl/noGLuses.inc} - SysUtils, Classes, Math, e_log, e_texture, SDL2, MAPDEF, ImagingTypes, Imaging, ImagingUtility; + {$IFDEF USE_SDL2} + SDL2, + {$ENDIF} + SysUtils, Classes, Math, e_log, e_texture, + MAPDEF, ImagingTypes, Imaging, ImagingUtility; type TMirrorType=(None, Horizontal, Vertical); @@ -129,8 +132,10 @@ procedure e_Clear(Mask: TGLbitfield; Red, Green, Blue: Single); overload; procedure e_Clear(); overload; procedure e_EndRender(); +{$IFDEF USE_SDL2} function e_GetGamma(win: PSDL_Window): Byte; procedure e_SetGamma(win: PSDL_Window;Gamma: Byte); +{$ENDIF} procedure e_MakeScreenshot(st: TStream; Width, Height: Word); @@ -1114,6 +1119,7 @@ begin glPopMatrix(); end; +{$IFDEF USE_SDL2} function e_GetGamma(win: PSDL_Window): Byte; var ramp: array [0..256*3-1] of Word; @@ -1176,6 +1182,7 @@ begin SDL_SetWindowGammaRamp(win, @ramp[0], @ramp[256], @ramp[512]); end; +{$ENDIF} function e_CharFont_Create(sp: ShortInt=0): DWORD; var @@ -1497,8 +1504,10 @@ end; procedure e_TextureFontBuild(Tex: DWORD; var FontID: DWORD; XCount, YCount: Word; Space: ShortInt=0); var +{$IF not DEFINED(USE_NANOGL) and not DEFINED(USE_NOGL)} loop1 : GLuint; cx, cy : real; +{$ENDIF} i, id: DWORD; begin if e_NoGraphics then Exit;