Skip to content
Snippets Groups Projects
Commit d056e82b authored by Ronald Kinard's avatar Ronald Kinard
Browse files

Parse GL version correctly.

parent d8484a86
No related branches found
No related tags found
No related merge requests found
...@@ -535,7 +535,7 @@ boolean SetupGLFunc13(void) ...@@ -535,7 +535,7 @@ boolean SetupGLFunc13(void)
// Parse the GL version // Parse the GL version
if (version != NULL) if (version != NULL)
{ {
if (sscanf(version, "%d.%d", &glmajor, &glminor) == 2) if (sscanf((const char*)version, "%d.%d", &glmajor, &glminor) == 2)
{ {
// Look, we gotta prepare for the inevitable arrival of GL 2.0 code... // Look, we gotta prepare for the inevitable arrival of GL 2.0 code...
switch (glmajor) switch (glmajor)
...@@ -543,6 +543,10 @@ boolean SetupGLFunc13(void) ...@@ -543,6 +543,10 @@ boolean SetupGLFunc13(void)
case 1: case 1:
if (glminor == 3) gl13 = true; if (glminor == 3) gl13 = true;
break; break;
case 2:
case 3:
case 4:
gl13 = true;
default: default:
break; break;
} }
...@@ -2400,12 +2404,8 @@ EXPORT void HWRAPI(MakeScreenFinalTexture) (void) ...@@ -2400,12 +2404,8 @@ EXPORT void HWRAPI(MakeScreenFinalTexture) (void)
EXPORT void HWRAPI(DrawScreenFinalTexture)(int width, int height) EXPORT void HWRAPI(DrawScreenFinalTexture)(int width, int height)
{ {
float xfix, yfix; float xfix, yfix;
int lmaxx, lmaxy;
INT32 texsize = 2048; INT32 texsize = 2048;
lmaxx = width < screen_width ? screen_width : width;
lmaxy = height < screen_height ? screen_height : height;
if(screen_width <= 1024) if(screen_width <= 1024)
texsize = 1024; texsize = 1024;
if(screen_width <= 512) if(screen_width <= 512)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment