Revision: 44117
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=44117
Author: dfelinto
Date: 2012-02-14 18:23:58 +0000 (Tue, 14 Feb 2012)
Log Message:
-----------
font objects in blenderplayer fail when object with alpha is rendered
the embed bge has its own DisableForText() routine which prepares the GL flags
for the text render.
For some reason blenderplayer is taking a slim approach and going straight for
the rendering. This routine helps to address this bug/case (non reported,
foundin my own project files). If need arises we should move this to its own
routine incorporating the other GL tests the embed bge performs.
Modified Paths:
--------------
trunk/blender/source/gameengine/GamePlayer/common/GPC_RenderTools.cpp
Modified: trunk/blender/source/gameengine/GamePlayer/common/GPC_RenderTools.cpp
===================================================================
--- trunk/blender/source/gameengine/GamePlayer/common/GPC_RenderTools.cpp
2012-02-14 17:48:05 UTC (rev 44116)
+++ trunk/blender/source/gameengine/GamePlayer/common/GPC_RenderTools.cpp
2012-02-14 18:23:58 UTC (rev 44117)
@@ -291,6 +291,29 @@
double*
mat,
float
aspect)
{
+ 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);
+ }
+
+ glActiveTextureARB(GL_TEXTURE0_ARB);
+ }
+ else {
+ 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);
+ }
+
/* the actual drawing */
glColor4fv(color);
_______________________________________________
Bf-blender-cvs mailing list
[email protected]
http://lists.blender.org/mailman/listinfo/bf-blender-cvs