[Scummvm-cvs-logs] SF.net SVN: scummvm:[50801] scummvm/branches/gsoc2010-opengl
mthreepwood at users.sourceforge.net
mthreepwood at users.sourceforge.net
Sun Jul 11 18:11:28 CEST 2010
Revision: 50801
http://scummvm.svn.sourceforge.net/scummvm/?rev=50801&view=rev
Author: mthreepwood
Date: 2010-07-11 16:11:28 +0000 (Sun, 11 Jul 2010)
Log Message:
-----------
Fix compile on Mac OS X.
Modified Paths:
--------------
scummvm/branches/gsoc2010-opengl/backends/graphics/opengl/gltexture.h
scummvm/branches/gsoc2010-opengl/backends/graphics/opengl/opengl-graphics.h
scummvm/branches/gsoc2010-opengl/backends/graphics/sdl/sdl-graphics.cpp
scummvm/branches/gsoc2010-opengl/configure
Modified: scummvm/branches/gsoc2010-opengl/backends/graphics/opengl/gltexture.h
===================================================================
--- scummvm/branches/gsoc2010-opengl/backends/graphics/opengl/gltexture.h 2010-07-11 11:52:17 UTC (rev 50800)
+++ scummvm/branches/gsoc2010-opengl/backends/graphics/opengl/gltexture.h 2010-07-11 16:11:28 UTC (rev 50801)
@@ -32,9 +32,12 @@
#undef ARRAYSIZE
#endif
-#ifdef USE_GLES
+#if defined(USE_GLES)
#include <GLES/gl.h>
#include <GLES/glext.h>
+#elif defined(MACOSX)
+#include <gl.h>
+#include <glext.h>
#else
#include <GL/gl.h>
#include <GL/glext.h>
Modified: scummvm/branches/gsoc2010-opengl/backends/graphics/opengl/opengl-graphics.h
===================================================================
--- scummvm/branches/gsoc2010-opengl/backends/graphics/opengl/opengl-graphics.h 2010-07-11 11:52:17 UTC (rev 50800)
+++ scummvm/branches/gsoc2010-opengl/backends/graphics/opengl/opengl-graphics.h 2010-07-11 16:11:28 UTC (rev 50801)
@@ -30,7 +30,7 @@
#include "backends/graphics/graphics.h"
enum {
- GFX_NORMAL = 0,
+ GFX_NORMAL = 0
};
/**
Modified: scummvm/branches/gsoc2010-opengl/backends/graphics/sdl/sdl-graphics.cpp
===================================================================
--- scummvm/branches/gsoc2010-opengl/backends/graphics/sdl/sdl-graphics.cpp 2010-07-11 11:52:17 UTC (rev 50800)
+++ scummvm/branches/gsoc2010-opengl/backends/graphics/sdl/sdl-graphics.cpp 2010-07-11 16:11:28 UTC (rev 50801)
@@ -1994,20 +1994,21 @@
int newMode = -1;
int factor = _videoMode.scaleFactor - 1;
+ SDLKey sdlKey = (SDLKey)key;
// Increase/decrease the scale factor
- if (key == SDLK_EQUALS || key == SDLK_PLUS || key == SDLK_MINUS ||
- key == SDLK_KP_PLUS || key == SDLK_KP_MINUS) {
- factor += (key == SDLK_MINUS || key == SDLK_KP_MINUS) ? -1 : +1;
+ if (sdlKey == SDLK_EQUALS || sdlKey == SDLK_PLUS || sdlKey == SDLK_MINUS ||
+ sdlKey == SDLK_KP_PLUS || sdlKey == SDLK_KP_MINUS) {
+ factor += (sdlKey == SDLK_MINUS || sdlKey == SDLK_KP_MINUS) ? -1 : +1;
if (0 <= factor && factor <= 3) {
newMode = s_gfxModeSwitchTable[_scalerType][factor];
}
}
- const bool isNormalNumber = (SDLK_1 <= key && key <= SDLK_9);
- const bool isKeypadNumber = (SDLK_KP1 <= key && key <= SDLK_KP9);
+ const bool isNormalNumber = (SDLK_1 <= sdlKey && sdlKey <= SDLK_9);
+ const bool isKeypadNumber = (SDLK_KP1 <= sdlKey && sdlKey <= SDLK_KP9);
if (isNormalNumber || isKeypadNumber) {
- _scalerType = key - (isNormalNumber ? SDLK_1 : SDLK_KP1);
+ _scalerType = sdlKey - (isNormalNumber ? SDLK_1 : SDLK_KP1);
if (_scalerType >= ARRAYSIZE(s_gfxModeSwitchTable))
return false;
Modified: scummvm/branches/gsoc2010-opengl/configure
===================================================================
--- scummvm/branches/gsoc2010-opengl/configure 2010-07-11 11:52:17 UTC (rev 50800)
+++ scummvm/branches/gsoc2010-opengl/configure 2010-07-11 16:11:28 UTC (rev 50801)
@@ -1335,7 +1335,8 @@
;;
darwin*)
DEFINES="$DEFINES -DUNIX -DMACOSX"
- LIBS="$LIBS -framework AudioUnit -framework AudioToolbox -framework Carbon -framework CoreMIDI"
+ CXXFLAGS="$CXXFLAGS -I/System/Library/Frameworks/OpenGL.framework/Headers"
+ LIBS="$LIBS -framework AudioUnit -framework AudioToolbox -framework Carbon -framework CoreMIDI -framework OpenGL"
add_line_to_config_mk 'MACOSX = 1'
;;
dreamcast)
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
More information about the Scummvm-git-logs
mailing list