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>2010-11-28 09:03:30 +0300
committerCampbell Barton <ideasman42@gmail.com>2010-11-28 09:03:30 +0300
commit34ea1cf0b23977ab76b23b06f6ceb1fda5631f88 (patch)
treefe8ed20a86405a088270ba5e8fef53ae1cb68972 /source/blender/blenkernel/intern/constraint.c
parent9d3a17922cad62f1f73ba60eef669a091a2b8687 (diff)
minor changes to the python api.
- pep8 script was giving an error on non utf8 scons source files. - use PyList_SET_ITEM macro when list type is ensured. - all mathutils types use subtypes to create new types when available. - use defines MAT3_UNITY, MAT4_UNITY to initialize unit matrices.
Diffstat (limited to 'source/blender/blenkernel/intern/constraint.c')
-rw-r--r--source/blender/blenkernel/intern/constraint.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/source/blender/blenkernel/intern/constraint.c b/source/blender/blenkernel/intern/constraint.c
index 076dae41e6a..f15e0bc3144 100644
--- a/source/blender/blenkernel/intern/constraint.c
+++ b/source/blender/blenkernel/intern/constraint.c
@@ -1202,12 +1202,11 @@ static void followpath_get_tarmat (bConstraint *con, bConstraintOb *cob, bConstr
if (VALID_CONS_TARGET(ct)) {
Curve *cu= ct->tar->data;
float vec[4], dir[3], radius;
- float totmat[4][4];
+ float totmat[4][4]= MAT4_UNITY;
float curvetime;
-
- unit_m4(totmat);
+
unit_m4(ct->matrix);
-
+
/* note: when creating constraints that follow path, the curve gets the CU_PATH set now,
* currently for paths to work it needs to go through the bevlist/displist system (ton)
*/
@@ -3106,11 +3105,11 @@ static void clampto_evaluate (bConstraint *con, bConstraintOb *cob, ListBase *ta
/* only evaluate if there is a target and it is a curve */
if (VALID_CONS_TARGET(ct) && (ct->tar->type == OB_CURVE)) {
Curve *cu= data->tar->data;
- float obmat[4][4], targetMatrix[4][4], ownLoc[3];
+ float obmat[4][4], ownLoc[3];
float curveMin[3], curveMax[3];
+ float targetMatrix[4][4]= MAT4_UNITY;
copy_m4_m4(obmat, cob->matrix);
- unit_m4(targetMatrix);
copy_v3_v3(ownLoc, obmat[3]);
INIT_MINMAX(curveMin, curveMax)