From 76e989d7b1303c877e8469513eae4ed746a8efe5 Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Tue, 30 Jul 2013 10:58:36 +0000 Subject: function renaming for own recently added BLI_math functions, suggested by Brecht. --- source/blender/blenlib/intern/math_matrix.c | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'source/blender/blenlib/intern/math_matrix.c') diff --git a/source/blender/blenlib/intern/math_matrix.c b/source/blender/blenlib/intern/math_matrix.c index 8565698110e..99342c4d6dc 100644 --- a/source/blender/blenlib/intern/math_matrix.c +++ b/source/blender/blenlib/intern/math_matrix.c @@ -1374,8 +1374,15 @@ void rotate_m2(float mat[2][2], const float angle) mat[1][0] = -mat[0][1]; } -/* scale or rotate around a non zero pivot */ -void pivot_m4(float mat[4][4], const float pivot[3]) +/** + * Scale or rotate around a pivot point, + * a convenience function to avoid having to do inline. + * + * Since its common to make a scale/rotation matrix that pivots around an arbitrary point. + * + * Typical use case is to make 3x3 matrix, copy to 4x4, then pass to this function. + */ +void transform_pivot_set_m4(float mat[4][4], const float pivot[3]) { float tmat[4][4]; -- cgit v1.2.3