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:
authorMartin Poirier <theeth@yahoo.com>2003-10-29 03:06:59 +0300
committerMartin Poirier <theeth@yahoo.com>2003-10-29 03:06:59 +0300
commit29f532588a23e7bb54d4414b0488b62cdf63062d (patch)
tree7c5ae56ce53b0ae77f1c226439f7a9a78669b083
parentfad1324e5aa48bc953956d1f4c4f82bb867d0bb4 (diff)
fixed the last bug with FollowPath (it didn't work with path without a speed IPO).
-rw-r--r--source/blender/blenkernel/intern/anim.c1
-rw-r--r--source/blender/blenkernel/intern/constraint.c11
2 files changed, 6 insertions, 6 deletions
diff --git a/source/blender/blenkernel/intern/anim.c b/source/blender/blenkernel/intern/anim.c
index 4fc5573bd51..a147aaf398f 100644
--- a/source/blender/blenkernel/intern/anim.c
+++ b/source/blender/blenkernel/intern/anim.c
@@ -212,7 +212,6 @@ int where_on_path(Object *ob, float ctime, float *vec, float *dir) /* returns OK
float *fp, *p0, *p1, *p2, *p3, fac;
float data[4];
int cycl=0, s0, s1, s2, s3;
-
if(ob==0 || ob->type != OB_CURVE) return 0;
cu= ob->data;
diff --git a/source/blender/blenkernel/intern/constraint.c b/source/blender/blenkernel/intern/constraint.c
index 999b6ce3cb2..6dbbf0d1697 100644
--- a/source/blender/blenkernel/intern/constraint.c
+++ b/source/blender/blenkernel/intern/constraint.c
@@ -546,11 +546,11 @@ short get_constraint_target (bConstraint *con, short ownertype, void* ownerdata,
curvetime = ctime - data->offset;
if(calc_ipo_spec(cu->ipo, CU_SPEED, &curvetime)==0) {
- ctime /= cu->pathlen;
- CLAMP(ctime, 0.0, 1.0);
+ curvetime /= cu->pathlen;
+ CLAMP(curvetime, 0.0, 1.0);
}
- if(where_on_path(data->tar, curvetime, vec, dir) ) {
+ if(where_on_path(data->tar, curvetime, vec, dir) ) {
if(data->followflag){
quat= vectoquat(dir, (short) data->trackflag, (short) data->upflag);
@@ -566,10 +566,11 @@ short get_constraint_target (bConstraint *con, short ownertype, void* ownerdata,
QuatToMat4(quat, totmat);
}
- VECCOPY(totmat[3], vec);
+ VECCOPY(totmat[3], vec);
- Mat4MulSerie(mat, data->tar->obmat, totmat, NULL, NULL, NULL, NULL, NULL, NULL);
+ Mat4MulSerie(mat, data->tar->obmat, totmat, NULL, NULL, NULL, NULL, NULL, NULL);
}
+
valid=1;
}
else