From d75390d09e42bc35d6897b6d71d14d56c238870c Mon Sep 17 00:00:00 2001 From: Eugenio Favalli Date: Wed, 13 Jul 2005 16:16:13 +0000 Subject: readding ifdefs --- src/graphics.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'src/graphics.cpp') diff --git a/src/graphics.cpp b/src/graphics.cpp index 5fbea504..dc6d0e75 100644 --- a/src/graphics.cpp +++ b/src/graphics.cpp @@ -35,6 +35,7 @@ Graphics::Graphics(): mouseCursor(NULL) { if (useOpenGL) { + #ifdef USE_OPENGL // Setup OpenGL glViewport(0, 0, 800, 600); glHint(GL_PERSPECTIVE_CORRECTION_HINT, GL_FASTEST); @@ -42,7 +43,7 @@ Graphics::Graphics(): SDL_GL_GetAttribute(SDL_GL_DOUBLEBUFFER, &gotDoubleBuffer); logger->log("Using OpenGL %s double buffering.", (gotDoubleBuffer ? "with" : "without")); - #ifdef USE_OPENGL + setTargetPlane(800, 600); #endif } @@ -151,9 +152,11 @@ void Graphics::updateScreen() } if (useOpenGL) { +#ifdef USE_OPENGL glFlush(); glFinish(); SDL_GL_SwapBuffers(); +#endif } else { SDL_Flip(screen); -- cgit v1.2.3-60-g2f50