diff options
author | Joshua Leung <aligorith@gmail.com> | 2009-04-15 16:59:49 +0400 |
---|---|---|
committer | Joshua Leung <aligorith@gmail.com> | 2009-04-15 16:59:49 +0400 |
commit | b68fb5df74941bcb998348a1f81cba3f51a8703d (patch) | |
tree | 5201d5f783dc4d05c2c67a5103b83c47fb5e0f36 /source/blender/blenkernel/intern/constraint.c | |
parent | 1680f5f2b01d0c48a1d8fcbcda3e90aa015bf6e7 (diff) |
Action Constraint: Optimisation attempt
Following on from the methods added specially for PoseLib to only execute the F-Curves in a given Action Group, I've attempted to use this for evaluating Action Constraints on Pose Channels. This does rely on the F-Curves being in groups named according to name of the Pose Channel of interest, hence, we may need some way to be able to fine tune this later.
Preliminary tests seem to be promising, with rigs with quite a few action constraints being slightly more responsive (subjective test though). Please test thoroughly.
Diffstat (limited to 'source/blender/blenkernel/intern/constraint.c')
-rw-r--r-- | source/blender/blenkernel/intern/constraint.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/source/blender/blenkernel/intern/constraint.c b/source/blender/blenkernel/intern/constraint.c index 1d88c794be6..c33149397e2 100644 --- a/source/blender/blenkernel/intern/constraint.c +++ b/source/blender/blenkernel/intern/constraint.c @@ -34,7 +34,6 @@ #include <float.h> #include "MEM_guardedalloc.h" -//XXX #include "nla.h" #include "BLI_blenlib.h" #include "BLI_arithb.h" @@ -1904,8 +1903,7 @@ static void actcon_get_tarmat (bConstraint *con, bConstraintOb *cob, bConstraint tchan= verify_pose_channel(pose, pchan->name); /* evaluate action using workob (it will only set the PoseChannel in question) */ - // XXX we need some flags to prevent evaluation from setting disabled flags on all other settings - what_does_obaction(cob->scene, cob->ob, &workob, pose, data->act, t); + what_does_obaction(cob->scene, cob->ob, &workob, pose, data->act, pchan->name, t); /* convert animation to matrices for use here */ chan_calc_mat(tchan); @@ -1918,7 +1916,8 @@ static void actcon_get_tarmat (bConstraint *con, bConstraintOb *cob, bConstraint Object workob; /* evaluate using workob */ - what_does_obaction(cob->scene, cob->ob, &workob, NULL, data->act, t); + // FIXME: we don't have any consistent standards on limiting effects on object... + what_does_obaction(cob->scene, cob->ob, &workob, NULL, data->act, NULL, t); object_to_mat4(&workob, ct->matrix); } else { |