From e1e49fd1a8a5bca7f95ba230a7daf12fb059779b Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Fri, 25 Nov 2016 16:20:30 +1100 Subject: Math Lib: rotate matrix cleanup - Remove 'rotate_m2', unlike 'rotate_m4' it created a new matrix duplicating 'angle_to_mat2' - now used instead. (better avoid matching functions having different behavior). - Add 'axis_angle_to_mat4_single', convenience wrapper for 'axis_angle_to_mat3_single'. - Replace 'unit_m4(), rotate_m4()' with a single call to 'axis_angle_to_mat4_single'. --- source/blender/editors/object/object_warp.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'source/blender/editors/object') diff --git a/source/blender/editors/object/object_warp.c b/source/blender/editors/object/object_warp.c index 9f4da87903d..92b82e2a31b 100644 --- a/source/blender/editors/object/object_warp.c +++ b/source/blender/editors/object/object_warp.c @@ -53,8 +53,7 @@ static void object_warp_calc_view_matrix(float r_mat_view[4][4], float r_center_ float viewmat_roll[4][4]; /* apply the rotation offset by rolling the view */ - unit_m4(mat_offset); - rotate_m4(mat_offset, 'Z', offset_angle); + axis_angle_to_mat4_single(mat_offset, 'Z', offset_angle); mul_m4_m4m4(viewmat_roll, mat_offset, viewmat); /* apply the view and the object matrix */ -- cgit v1.2.3