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:
authorCampbell Barton <ideasman42@gmail.com>2011-02-02 03:40:55 +0300
committerCampbell Barton <ideasman42@gmail.com>2011-02-02 03:40:55 +0300
commit95df65f1b55d311be4171f71bb106f9c7d193a79 (patch)
tree9ceafdf50ae1afbb903722ae4979d85ad7dd300f /source/blender/blenlib/intern/math_vector_inline.c
parent19efa4301a5f2545eddfd4e5e56943d9a1d9f5cf (diff)
- some parts of the code to remove rotation were not removing axis/angle rotation (only functional change of this commit).
- use BLI_math functions for removing rotations from objects and pose channels. - add unit_axis_angle() to avoid setting the Y axis inline anywhere rotation needs removing.
Diffstat (limited to 'source/blender/blenlib/intern/math_vector_inline.c')
-rw-r--r--source/blender/blenlib/intern/math_vector_inline.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/source/blender/blenlib/intern/math_vector_inline.c b/source/blender/blenlib/intern/math_vector_inline.c
index 8f00e7b6d0c..a01455c8df0 100644
--- a/source/blender/blenlib/intern/math_vector_inline.c
+++ b/source/blender/blenlib/intern/math_vector_inline.c
@@ -282,6 +282,14 @@ MINLINE void negate_v3_v3(float r[3], const float a[3])
r[2]= -a[2];
}
+MINLINE void negate_v4(float r[4])
+{
+ r[0]= -r[0];
+ r[1]= -r[1];
+ r[2]= -r[2];
+ r[3]= -r[3];
+}
+
MINLINE float dot_v2v2(const float a[2], const float b[2])
{
return a[0]*b[0] + a[1]*b[1];