diff options
author | Joshua Leung <aligorith@gmail.com> | 2010-01-20 00:44:22 +0300 |
---|---|---|
committer | Joshua Leung <aligorith@gmail.com> | 2010-01-20 00:44:22 +0300 |
commit | 7165008b354ed1a47a4f2c8f9a384f995c899935 (patch) | |
tree | 6ca530aae03cd506bef72517194a2261dba6d69c /source/blender/editors/transform | |
parent | 886a5bca08b43501208502c44281449278863ffe (diff) |
Motion Paths are now recalculated again after transforms (with autokeying and around-current frame displays enabled)
Diffstat (limited to 'source/blender/editors/transform')
-rw-r--r-- | source/blender/editors/transform/transform_conversions.c | 20 |
1 files changed, 16 insertions, 4 deletions
diff --git a/source/blender/editors/transform/transform_conversions.c b/source/blender/editors/transform/transform_conversions.c index ebd25271a8a..8033a340a43 100644 --- a/source/blender/editors/transform/transform_conversions.c +++ b/source/blender/editors/transform/transform_conversions.c @@ -4708,8 +4708,8 @@ void autokeyframe_pose_cb_func(bContext *C, Scene *scene, View3D *v3d, Object *o /* do the bone paths * NOTE: only do this when there is context info */ - if (C && (arm->pathflag & ARM_PATH_ACFRA)) { - //pose_clear_paths(ob); // XXX for now, don't need to clear + if (C && (ob->pose->avs.path_type == MOTIONPATH_TYPE_ACFRA)) { + //ED_pose_clear_paths(C, ob); // XXX for now, don't need to clear ED_pose_recalculate_paths(C, scene, ob); } } @@ -4963,7 +4963,7 @@ void special_aftertrans_update(bContext *C, TransInfo *t) ; } else { /* Objects */ - int i; + int i, recalcObPaths=0; for (i = 0; i < t->total; i++) { TransData *td = t->data + i; @@ -4996,8 +4996,20 @@ void special_aftertrans_update(bContext *C, TransInfo *t) DAG_id_flush_update(&ob->id, OB_RECALC_OB); /* Set autokey if necessary */ - if (!cancelled) + if (!cancelled) { autokeyframe_ob_cb_func(C, t->scene, (View3D *)t->view, ob, t->mode); + + if (ob->avs.path_type == MOTIONPATH_TYPE_ACFRA) + recalcObPaths= 1; + } + } + + /* recalculate motion paths for objects (if necessary) + * NOTE: only do this when there is context info + */ + if (C && recalcObPaths) { + //ED_objects_clear_paths(C); // XXX for now, don't need to clear + ED_objects_recalculate_paths(C, t->scene); } } |