[Bf-blender-cvs] [adb422e500] blender2.8: OpenGL: fix MultMatrix order

Mike Erwin noreply at git.blender.org
Wed Feb 1 00:21:48 CET 2017


Commit: adb422e5005b5051c2ec6d78b12ec643a3b04c7a
Author: Mike Erwin
Date:   Tue Jan 31 17:03:07 2017 -0500
Branches: blender2.8
https://developer.blender.org/rBadb422e5005b5051c2ec6d78b12ec643a3b04c7a

OpenGL: fix MultMatrix order

Partial revert of rB06d4aca87956

Problem found while converting old GL matrix calls to new API (T49450)

===================================================================

M	source/blender/gpu/intern/gpu_matrix.c

===================================================================

diff --git a/source/blender/gpu/intern/gpu_matrix.c b/source/blender/gpu/intern/gpu_matrix.c
index 19ff856b68..b70aa4b770 100644
--- a/source/blender/gpu/intern/gpu_matrix.c
+++ b/source/blender/gpu/intern/gpu_matrix.c
@@ -281,7 +281,7 @@ void gpuScale3fv(const float vec[3])
 void gpuMultMatrix3D(const float m[4][4])
 {
 	BLI_assert(state.mode == MATRIX_MODE_3D);
-	mul_m4_m4_pre(ModelView3D, m);
+	mul_m4_m4_post(ModelView3D, m);
 	CHECKMAT(ModelView3D);
 	state.dirty = true;
 }
@@ -289,7 +289,7 @@ void gpuMultMatrix3D(const float m[4][4])
 void gpuMultMatrix2D(const float m[3][3])
 {
 	BLI_assert(state.mode == MATRIX_MODE_2D);
-	mul_m3_m3_pre(ModelView2D, m);
+	mul_m3_m3_post(ModelView2D, m);
 	CHECKMAT(ModelView2D);
 	state.dirty = true;
 }




More information about the Bf-blender-cvs mailing list