Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'source/blender/editors/space_view3d/drawsimdebug.c')
-rw-r--r--source/blender/editors/space_view3d/drawsimdebug.c15
1 files changed, 7 insertions, 8 deletions
diff --git a/source/blender/editors/space_view3d/drawsimdebug.c b/source/blender/editors/space_view3d/drawsimdebug.c
index 2baa6304cd9..5984633112d 100644
--- a/source/blender/editors/space_view3d/drawsimdebug.c
+++ b/source/blender/editors/space_view3d/drawsimdebug.c
@@ -41,17 +41,16 @@
#include "BKE_effect.h"
#include "GPU_immediate.h"
+#include "GPU_matrix.h"
#include "view3d_intern.h"
-#include "BIF_gl.h"
-
static void draw_sim_debug_elements(SimDebugData *debug_data, float imat[4][4])
{
- VertexFormat* format = immVertexFormat();
- unsigned pos = add_attrib(format, "pos", GL_FLOAT, 3, KEEP_FLOAT);
- unsigned color = add_attrib(format, "color", GL_FLOAT, 3, KEEP_FLOAT);
+ VertexFormat *format = immVertexFormat();
+ unsigned int pos = add_attrib(format, "pos", GL_FLOAT, 3, KEEP_FLOAT);
+ unsigned int color = add_attrib(format, "color", GL_FLOAT, 3, KEEP_FLOAT);
immBindBuiltinProgram(GPU_SHADER_3D_FLAT_COLOR);
@@ -199,12 +198,12 @@ void draw_sim_debug_data(Scene *UNUSED(scene), View3D *v3d, ARegion *ar)
invert_m4_m4(imat, rv3d->viewmatob);
- glPushMatrix();
- glLoadMatrixf(rv3d->viewmat);
+ gpuPushMatrix();
+ gpuLoadMatrix3D(rv3d->viewmat);
view3d_cached_text_draw_begin();
draw_sim_debug_elements(_sim_debug_data, imat);
view3d_cached_text_draw_end(v3d, ar, false, NULL);
- glPopMatrix();
+ gpuPopMatrix();
}