Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'source/gameengine/BlenderRoutines/KX_BlenderGL.cpp')
-rw-r--r--source/gameengine/BlenderRoutines/KX_BlenderGL.cpp52
1 files changed, 12 insertions, 40 deletions
diff --git a/source/gameengine/BlenderRoutines/KX_BlenderGL.cpp b/source/gameengine/BlenderRoutines/KX_BlenderGL.cpp
index 2a5cc14018f..230d6b262c6 100644
--- a/source/gameengine/BlenderRoutines/KX_BlenderGL.cpp
+++ b/source/gameengine/BlenderRoutines/KX_BlenderGL.cpp
@@ -44,21 +44,9 @@
#include "BMF_Api.h"
+#include "GL/glew.h"
+#include "BIF_gl.h"
-#ifdef __APPLE__
-#define GL_GLEXT_LEGACY 1
-#include <OpenGL/gl.h>
-#include <OpenGL/glu.h>
-#else
-#include <GL/gl.h>
-#if defined(__sun__) && !defined(__sparc__)
-#include <mesa/glu.h>
-#else
-#include <GL/glu.h>
-#endif
-#endif
-#include "RAS_OpenGLRasterizer/RAS_GLExtensionManager.h"
-#include "RAS_OpenGLRasterizer/ARB_multitexture.h"
#include "BL_Material.h" // MAXTEX
/* Data types encoding the game world: */
@@ -77,7 +65,6 @@
#include "BKE_bmfont.h"
#include "BKE_image.h"
-#include "BIF_gl.h"
extern "C" {
#include "BDR_drawmesh.h"
#include "BIF_mywindow.h"
@@ -88,12 +75,6 @@ extern "C" {
/* end of blender block */
-#ifdef __APPLE__
-#include <OpenGL/gl.h>
-#else
-#include <GL/gl.h>
-#endif
-
/* was in drawmesh.c */
void spack(unsigned int ucol)
{
@@ -194,27 +175,18 @@ void DisableForText()
glDisable(GL_LIGHTING);
glDisable(GL_COLOR_MATERIAL);
}
-#if defined(GL_ARB_multitexture) && defined(WITH_GLEXT)
- if (!getenv("WITHOUT_GLEXT")) {
- for(int i=0; i<MAXTEX; i++) {
- if(bgl::RAS_EXT_support._ARB_multitexture)
- bgl::blActiveTextureARB(GL_TEXTURE0_ARB+i);
-#ifdef GL_ARB_texture_cube_map
- if(bgl::RAS_EXT_support._ARB_texture_cube_map)
- if(glIsEnabled(GL_TEXTURE_CUBE_MAP_ARB))
- glDisable(GL_TEXTURE_CUBE_MAP_ARB);
-#endif
- if(glIsEnabled(GL_TEXTURE_2D)) glDisable(GL_TEXTURE_2D);
- }
- } else {
- if(glIsEnabled(GL_TEXTURE_2D)) glDisable(GL_TEXTURE_2D);
- }
-#else//GL_ARB_multitexture
- if(glIsEnabled(GL_TEXTURE_2D)) glDisable(GL_TEXTURE_2D);
-#endif
-}
+ if(GLEW_ARB_multitexture)
+ for(int i=0; i<MAXTEX; i++)
+ glActiveTextureARB(GL_TEXTURE0_ARB+i);
+
+ if(GLEW_ARB_texture_cube_map)
+ if(glIsEnabled(GL_TEXTURE_CUBE_MAP_ARB))
+ glDisable(GL_TEXTURE_CUBE_MAP_ARB);
+ if(glIsEnabled(GL_TEXTURE_2D))
+ glDisable(GL_TEXTURE_2D);
+}
void BL_print_gamedebug_line(char* text, int xco, int yco, int width, int height)
{