[Bf-blender-cvs] [acf6db7e2b6] custom-manipulators: Update to use GPU matrix

Campbell Barton noreply at git.blender.org
Mon May 29 06:42:22 CEST 2017


Commit: acf6db7e2b6149acf95c44ddc7f816ffcb85945c
Author: Campbell Barton
Date:   Mon May 29 14:40:36 2017 +1000
Branches: custom-manipulators
https://developer.blender.org/rBacf6db7e2b6149acf95c44ddc7f816ffcb85945c

Update to use GPU matrix

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

M	source/blender/windowmanager/manipulators/intern/manipulator_library/facemap_manipulator.c

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

diff --git a/source/blender/windowmanager/manipulators/intern/manipulator_library/facemap_manipulator.c b/source/blender/windowmanager/manipulators/intern/manipulator_library/facemap_manipulator.c
index 76a714d0ebb..d988b4f7098 100644
--- a/source/blender/windowmanager/manipulators/intern/manipulator_library/facemap_manipulator.c
+++ b/source/blender/windowmanager/manipulators/intern/manipulator_library/facemap_manipulator.c
@@ -49,6 +49,7 @@
 #include "ED_view3d.h"
 
 #include "GPU_select.h"
+#include "GPU_matrix.h"
 
 #include "MEM_guardedalloc.h"
 
@@ -74,11 +75,11 @@ static void widget_facemap_draw(const bContext *C, struct wmManipulator *widget)
 	FacemapManipulator *fmap_widget = (FacemapManipulator *)widget;
 	const float *col = (widget->state & WM_MANIPULATOR_SELECTED) ? widget->col_hi : widget->col;
 
-	glPushMatrix();
-	glMultMatrixf(fmap_widget->ob->obmat);
-	glTranslatef(UNPACK3(widget->offset));
+	gpuPushMatrix();
+	gpuMultMatrix(fmap_widget->ob->obmat);
+	gpuTranslate3fv(widget->offset);
 	ED_draw_object_facemap(CTX_data_scene(C), fmap_widget->ob, col, fmap_widget->facemap);
-	glPopMatrix();
+	gpuPopMatrix();
 }
 
 static void widget_facemap_render_3d_intersect(const bContext *C, struct wmManipulator *widget, int selectionbase)




More information about the Bf-blender-cvs mailing list