summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/mobileopenglgraphics.cpp8
-rw-r--r--src/normalopenglgraphics.cpp9
-rw-r--r--src/safeopenglgraphics.cpp9
3 files changed, 26 insertions, 0 deletions
diff --git a/src/mobileopenglgraphics.cpp b/src/mobileopenglgraphics.cpp
index f3c4d1326..b1eab09cd 100644
--- a/src/mobileopenglgraphics.cpp
+++ b/src/mobileopenglgraphics.cpp
@@ -852,6 +852,14 @@ void MobileOpenGLGraphics::_beginDraw()
glEnable(GL_SCISSOR_TEST);
glDisable(GL_DITHER);
+ glDisable(GL_LIGHTING);
+ glDisable(GL_DEPTH_TEST);
+ glDisable(GL_FOG);
+ glDisable(GL_COLOR_LOGIC_OP);
+ glDisable(GL_COLOR_MATERIAL);
+ glDisable(GL_STENCIL_TEST);
+
+ glShadeModel(GL_FLAT);
glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
diff --git a/src/normalopenglgraphics.cpp b/src/normalopenglgraphics.cpp
index 837bb27db..534e9bffe 100644
--- a/src/normalopenglgraphics.cpp
+++ b/src/normalopenglgraphics.cpp
@@ -1049,12 +1049,21 @@ void NormalOpenGLGraphics::_beginDraw()
glEnable(GL_SCISSOR_TEST);
glDisable(GL_DITHER);
+ glDisable(GL_LIGHTING);
+ glDisable(GL_DEPTH_TEST);
+ glDisable(GL_FOG);
+ glDisable(GL_COLOR_LOGIC_OP);
+ glDisable(GL_COLOR_MATERIAL);
+ glDisable(GL_STENCIL_TEST);
glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
glEnableClientState(GL_VERTEX_ARRAY);
glDisableClientState(GL_TEXTURE_COORD_ARRAY);
+ glShadeModel(GL_FLAT);
+ glDepthMask(GL_FALSE);
+
#ifndef ANDROID
glHint(GL_LINE_SMOOTH_HINT, GL_FASTEST);
glHint(GL_PERSPECTIVE_CORRECTION_HINT, GL_FASTEST);
diff --git a/src/safeopenglgraphics.cpp b/src/safeopenglgraphics.cpp
index 5b4a0cc87..5802691ec 100644
--- a/src/safeopenglgraphics.cpp
+++ b/src/safeopenglgraphics.cpp
@@ -374,6 +374,15 @@ void SafeOpenGLGraphics::_beginDraw()
glLoadIdentity();
glEnable(GL_SCISSOR_TEST);
+ glDisable(GL_DITHER);
+ glDisable(GL_LIGHTING);
+ glDisable(GL_DEPTH_TEST);
+ glDisable(GL_FOG);
+ glDisable(GL_COLOR_LOGIC_OP);
+ glDisable(GL_COLOR_MATERIAL);
+ glDisable(GL_STENCIL_TEST);
+
+ glShadeModel(GL_FLAT);
glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);