From b6b61681efd322bd800bcaba55099cdf147547b2 Mon Sep 17 00:00:00 2001 From: Martin Poirier Date: Mon, 29 Dec 2008 01:41:28 +0000 Subject: 2.5 Transform: First working port of the transform code: - Object mode only (other conversions need to be ported) - Contraints (global and local only) working - Snap (no edit mode, obviously) working - Numinput working - Gears (Ctrl and Shift) working - Only grap, rotate, scale, shear, warp and to sphere have been added as hotkey, but the rest should work too once accessible - No manipulator - No drawn feedback other than moving stuff and header print (no constraint line, snap circle, ...) - No NDOF support I've only tested Scons support, though Makefil *should* work, I *think*. Misc: -QuatIsNull function in arith -Exporting project_* and view[line|ray] functions from view3d --- source/blender/blenlib/BLI_arithb.h | 1 + source/blender/blenlib/intern/arithb.c | 4 ++++ 2 files changed, 5 insertions(+) (limited to 'source/blender/blenlib') diff --git a/source/blender/blenlib/BLI_arithb.h b/source/blender/blenlib/BLI_arithb.h index 186681fad7d..8c55a83785b 100644 --- a/source/blender/blenlib/BLI_arithb.h +++ b/source/blender/blenlib/BLI_arithb.h @@ -123,6 +123,7 @@ void Mat3ToCompatibleEul(float mat[][3], float *eul, float *oldrot); * @section Quaternion arithmetic routines */ +int QuatIsNul(float *q); void QuatToEul(float *quat, float *eul); void QuatOne(float *); void QuatMul(float *, float *, float *); diff --git a/source/blender/blenlib/intern/arithb.c b/source/blender/blenlib/intern/arithb.c index a47d37eb69a..4d555a009c5 100644 --- a/source/blender/blenlib/intern/arithb.c +++ b/source/blender/blenlib/intern/arithb.c @@ -1087,6 +1087,10 @@ void printmatrix3( char *str, float m[][3]) /* **************** QUATERNIONS ********** */ +int QuatIsNul(float *q) +{ + return (q[0] == 0 && q[1] == 0 && q[2] == 0 && q[3] == 0); +} void QuatMul(float *q, float *q1, float *q2) { -- cgit v1.2.3