[Super-tux-commit] supertux/src setup.cpp,1.65,1.66 texture.cpp,1.18,1.19 texture.h,1.19,1.20
Brought to you by:
wkendrick
From: Ingo R. <gr...@us...> - 2004-05-01 16:39:17
|
Update of /cvsroot/super-tux/supertux/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv11170 Modified Files: setup.cpp texture.cpp texture.h Log Message: - fixed compile with opengl disabled Index: setup.cpp =================================================================== RCS file: /cvsroot/super-tux/supertux/src/setup.cpp,v retrieving revision 1.65 retrieving revision 1.66 diff -u -d -r1.65 -r1.66 --- setup.cpp 29 Apr 2004 13:36:30 -0000 1.65 +++ setup.cpp 1 May 2004 16:39:08 -0000 1.66 @@ -391,7 +391,7 @@ #ifndef NOOPENGL options_menu->additem(MN_TOGGLE,"OpenGL",use_gl,0, MNID_OPENGL); #else - options_menu->additem(MN_DEACTIVE,"OpenGL (not supported)",use_gl,MNID_OPENGL); + options_menu->additem(MN_DEACTIVE,"OpenGL (not supported)",use_gl, 0, MNID_OPENGL); #endif options_menu->additem(MN_TOGGLE,"Fullscreen",use_fullscreen,0, MNID_FULLSCREEN); if(audio_device) Index: texture.h =================================================================== RCS file: /cvsroot/super-tux/supertux/src/texture.h,v retrieving revision 1.19 retrieving revision 1.20 diff -u -d -r1.19 -r1.20 --- texture.h 26 Apr 2004 12:21:22 -0000 1.19 +++ texture.h 1 May 2004 16:39:08 -0000 1.20 @@ -123,6 +123,7 @@ int draw_part(float sx, float sy, float x, float y, float w, float h, Uint8 alpha, bool update); }; +#ifndef NOOPENGL class SurfaceOpenGL : public SurfaceImpl { public: @@ -141,6 +142,7 @@ private: void create_gl(SDL_Surface * surf, GLuint * tex); }; +#endif #endif /*SUPERTUX_TEXTURE_H*/ Index: texture.cpp =================================================================== RCS file: /cvsroot/super-tux/supertux/src/texture.cpp,v retrieving revision 1.18 retrieving revision 1.19 diff -u -d -r1.18 -r1.19 --- texture.cpp 1 May 2004 11:14:40 -0000 1.18 +++ texture.cpp 1 May 2004 16:39:08 -0000 1.19 @@ -66,10 +66,14 @@ SurfaceImpl* SurfaceData::create() { +#ifndef NOOPENGL if (use_gl) return create_SurfaceOpenGL(); else return create_SurfaceSDL(); +#else + return create_SurfaceSDL(); +#endif } SurfaceSDL* @@ -90,6 +94,7 @@ SurfaceOpenGL* SurfaceData::create_SurfaceOpenGL() { +#ifndef NOOPENGL switch(type) { case LOAD: @@ -99,10 +104,11 @@ case SURFACE: return new SurfaceOpenGL(surface, use_alpha); } +#endif assert(0); } - +#ifndef NOOPENGL /* Quick utility function for texture creation */ static int power_of_two(int input) { @@ -113,6 +119,7 @@ } return value; } +#endif Surface::Surface(SDL_Surface* surf, int use_alpha) : data(surf, use_alpha), w(0), h(0) |