From 142828005444e13c7edeaf751aaab6a90a9f75fd Mon Sep 17 00:00:00 2001 From: Georges Basile Stavracas Neto Date: Tue, 12 Mar 2019 14:35:33 -0300 Subject: [PATCH] cogl/matrix: Fix rotation --- cogl/cogl/cogl-matrix.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/cogl/cogl/cogl-matrix.c b/cogl/cogl/cogl-matrix.c index 449e90b03..70393f340 100644 --- a/cogl/cogl/cogl-matrix.c +++ b/cogl/cogl/cogl-matrix.c @@ -156,14 +156,11 @@ cogl_matrix_rotate (CoglMatrix *matrix, float y, float z) { - graphene_matrix_t rotation, m; + graphene_matrix_t m; graphene_vec3_t r; cogl_matrix_to_graphene_matrix (matrix, &m); - - graphene_matrix_init_rotate (&rotation, angle, graphene_vec3_init (&r, x, y, z)); - graphene_matrix_multiply (&rotation, &m, &m); - + graphene_matrix_rotate (&m, angle, graphene_vec3_init (&r, x, y, z)); graphene_matrix_to_cogl_matrix (&m, matrix); _COGL_MATRIX_DEBUG_PRINT (matrix);