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
path: root/source
diff options
context:
space:
mode:
authorMartin Poirier <theeth@yahoo.com>2004-03-09 20:21:08 +0300
committerMartin Poirier <theeth@yahoo.com>2004-03-09 20:21:08 +0300
commit44cf2c587de540cbaab237be50a807c18210c979 (patch)
treedf899a2fcd2fa570733b8a0e24040ac6551b58e4 /source
parentf5d3649d17690522f67edbe3e5b860d1924bf9f2 (diff)
Constraint blending and accumulator fixes for bug #924 and #983
924: Constraints (especially tracking) on objects with non uniform scaling was screwing the orientation of the object badly 983: Two or more Follow Path constraint on one object was fubar Fixing 983 enables nice tricks like this: http://www.clubinfo.bdeb.qc.ca/~theeth/Work/Path.blend URLs for both bugs: http://projects.blender.org/tracker/index.php?func=detail&aid=924&group_id=9&atid=125 http://projects.blender.org/tracker/index.php?func=detail&aid=983&group_id=9&atid=125
Diffstat (limited to 'source')
-rw-r--r--source/blender/blenkernel/intern/object.c11
1 files changed, 7 insertions, 4 deletions
diff --git a/source/blender/blenkernel/intern/object.c b/source/blender/blenkernel/intern/object.c
index ac795df3375..0145f962142 100644
--- a/source/blender/blenkernel/intern/object.c
+++ b/source/blender/blenkernel/intern/object.c
@@ -1376,7 +1376,7 @@ void solve_tracking (Object *ob, float targetmat[][4])
else Mat4CpyMat4(tmat, ob->obmat);
Mat4MulMat34(ob->obmat, totmat, tmat);
-
+
}
void where_is_object(Object *ob)
@@ -1480,6 +1480,8 @@ void solve_constraints (Object *ob, short obtype, void *obdata, float ctime)
/* Extract the components & accumulate */
Mat4ToQuat(focusmat, quat);
VECCOPY(loc, focusmat[3]);
+ Mat3CpyMat4(mat, focusmat);
+ Mat3ToSize(mat, size);
a+=enf;
tot++;
@@ -1516,7 +1518,7 @@ void solve_constraints (Object *ob, short obtype, void *obdata, float ctime)
Mat3MulMat3(mat, rmat, smat);
Mat4CpyMat3(focusmat, mat);
VECCOPY(focusmat[3], aloc);
-
+
evaluate_constraint(con, ob, obtype, obdata, focusmat);
}
@@ -1537,11 +1539,11 @@ void solve_constraints (Object *ob, short obtype, void *obdata, float ctime)
/* Interpolate the enforcement */
Mat4Invert (imat, oldmat);
- Mat4MulMat4 (delta, solution, imat);
+ Mat4MulMat4 (delta, imat, solution);
Mat4One(identity);
Mat4BlendMat4(delta, identity, delta, a);
- Mat4MulMat4 (ob->obmat, delta, oldmat);
+ Mat4MulMat4 (ob->obmat, oldmat, delta);
}
else{
@@ -1561,6 +1563,7 @@ void solve_constraints (Object *ob, short obtype, void *obdata, float ctime)
}
}
}
+
void what_does_parent1(Object *par, int partype, int par1, int par2, int par3)
{