[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [28098] trunk/blender/source/blender/gpu/ intern/gpu_draw.c: Bugfix: 21586 - UI problems with Tiled Textures ( animatable for GE)

Dalai Felinto dfelinto at gmail.com
Thu Apr 8 22:58:18 CEST 2010


Revision: 28098
          http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=28098
Author:   dfelinto
Date:     2010-04-08 22:58:18 +0200 (Thu, 08 Apr 2010)

Log Message:
-----------
Bugfix: 21586 - UI problems with Tiled Textures (animatable for GE)
The problem was present in Blender 2.49, but it didn't produce any side effect.
glScale was changing the texture matrix and the matrix was never been reset. That messes up with UI drawing.

Modified Paths:
--------------
    trunk/blender/source/blender/gpu/intern/gpu_draw.c

Modified: trunk/blender/source/blender/gpu/intern/gpu_draw.c
===================================================================
--- trunk/blender/source/blender/gpu/intern/gpu_draw.c	2010-04-08 16:36:50 UTC (rev 28097)
+++ trunk/blender/source/blender/gpu/intern/gpu_draw.c	2010-04-08 20:58:18 UTC (rev 28098)
@@ -1097,6 +1097,14 @@
 	GMS.matbuf= NULL;
 	GMS.gmatbuf= NULL;
 	GMS.blendmode= NULL;
+
+	/* resetting the texture matrix after the glScale needed for tiled textures */
+	if(GTS.tilemode)
+	{
+		glMatrixMode(GL_TEXTURE);
+		glLoadIdentity();
+		glMatrixMode(GL_MODELVIEW);
+	}
 }
 
 /* Lights */





More information about the Bf-blender-cvs mailing list