diff options
author | Campbell Barton <ideasman42@gmail.com> | 2013-01-12 18:28:23 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2013-01-12 18:28:23 +0400 |
commit | c93e127e7a2040f74655937fedb5a9d439c03aa9 (patch) | |
tree | 6ef646a840f21f5ef6e5b5f162c0639459f9c485 /source/blender/blenlib/intern | |
parent | aab01c86cf56f5d21d2503f7e854bb19b07ca2c6 (diff) |
code cleanup: style and replace (float)sin, (float)cos with sinf, cosf
Diffstat (limited to 'source/blender/blenlib/intern')
-rw-r--r-- | source/blender/blenlib/intern/math_matrix.c | 4 | ||||
-rw-r--r-- | source/blender/blenlib/intern/math_rotation.c | 8 |
2 files changed, 6 insertions, 6 deletions
diff --git a/source/blender/blenlib/intern/math_matrix.c b/source/blender/blenlib/intern/math_matrix.c index 02fc5b07d6d..6784c4145a5 100644 --- a/source/blender/blenlib/intern/math_matrix.c +++ b/source/blender/blenlib/intern/math_matrix.c @@ -1245,8 +1245,8 @@ void rotate_m4(float mat[4][4], const char axis, const float angle) assert(axis >= 'X' && axis <= 'Z'); - cosine = (float)cos(angle); - sine = (float)sin(angle); + cosine = cosf(angle); + sine = sinf(angle); switch (axis) { case 'X': for (col = 0; col < 4; col++) diff --git a/source/blender/blenlib/intern/math_rotation.c b/source/blender/blenlib/intern/math_rotation.c index 71f146e8131..dc54bf9ace3 100644 --- a/source/blender/blenlib/intern/math_rotation.c +++ b/source/blender/blenlib/intern/math_rotation.c @@ -589,10 +589,10 @@ void interp_qt_qtqt(float result[4], const float quat1[4], const float quat2[4], } if ((1.0f - cosom) > 0.0001f) { - omega = (float)acos(cosom); - sinom = (float)sin(omega); - sc1 = (float)sin((1 - t) * omega) / sinom; - sc2 = (float)sin(t * omega) / sinom; + omega = acosf(cosom); + sinom = sinf(omega); + sc1 = sinf((1.0f - t) * omega) / sinom; + sc2 = sinf(t * omega) / sinom; } else { sc1 = 1.0f - t; |