Skip to content

Commit

Permalink
Fixed FTBFS errors under *nix.
Browse files Browse the repository at this point in the history
  • Loading branch information
danij committed Jan 13, 2008
1 parent 2e62439 commit b63dc93
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
9 changes: 5 additions & 4 deletions doomsday/engine/unix/src/dgl_main.c
Expand Up @@ -75,7 +75,7 @@ boolean DGL_ChangeVideoMode(int width, int height, int bpp)
{
int flags = SDL_OPENGL;

if(!windowed)
if(!DGL_state.windowed)
flags |= SDL_FULLSCREEN;

if(!SDL_SetVideoMode(width, height, bpp, flags))
Expand All @@ -93,7 +93,8 @@ boolean DGL_ChangeVideoMode(int width, int height, int bpp)
static boolean initOpenGL(void)
{
// Attempt to set the video mode.
if(!DGL_ChangeVideoMode(screenWidth, screenHeight, screenBits))
if(!DGL_ChangeVideoMode(DGL_state.screenWidth, DGL_state.screenHeight,
DGL_state.screenBits))
return false;

// Setup the GL state like we want it.
Expand Down Expand Up @@ -160,9 +161,9 @@ boolean DG_CreateContext(int width, int height, int bpp, boolean windowed,
strcpy(extbuf, token);

// Check the maximum texture size.
glGetIntegerv(GL_MAX_TEXTURE_SIZE, (GLint*) &DGL_state.maxTexSize);
glGetIntegerv(GL_MAX_TEXTURE_SIZE, &((GLint) DGL_state.maxTexSize));

DG_InitExtensions();
DGL_InitExtensions();

if(firstTimeInit)
{
Expand Down
2 changes: 1 addition & 1 deletion doomsday/engine/win32/src/dgl_main.c
Expand Up @@ -232,7 +232,7 @@ static void checkExtensions(void)
}
Con_Message(" GLU Version: %s\n", gluGetString(GLU_VERSION));

glGetIntegerv(GL_MAX_TEXTURE_UNITS, &DGL_state.maxTexUnits);
glGetIntegerv(GL_MAX_TEXTURE_UNITS, &((GLint) DGL_state.maxTexUnits));
Con_Message(" Found Texture units: %i\n", DGL_state.maxTexUnits);
#ifndef USE_MULTITEXTURE
DGL_state.maxTexUnits = 1;
Expand Down

0 comments on commit b63dc93

Please sign in to comment.