diff options
-rw-r--r-- | source/blender/blenkernel/intern/constraint.c | 3 | ||||
-rw-r--r-- | source/blender/draw/engines/overlay/overlay_extra.c | 2 | ||||
-rw-r--r-- | source/blender/editors/transform/transform_mode.c | 3 |
3 files changed, 8 insertions, 0 deletions
diff --git a/source/blender/blenkernel/intern/constraint.c b/source/blender/blenkernel/intern/constraint.c index 8400d610a32..c32a6c6c515 100644 --- a/source/blender/blenkernel/intern/constraint.c +++ b/source/blender/blenkernel/intern/constraint.c @@ -6259,6 +6259,9 @@ void BKE_constraint_target_matrix_get(struct Depsgraph *depsgraph, } } + /* Initialize the custom space for use in calculating the matrices. */ + BKE_constraint_custom_object_space_init(cob, con); + /* get targets - we only need the first one though (and there should only be one) */ cti->get_constraint_targets(con, &targets); diff --git a/source/blender/draw/engines/overlay/overlay_extra.c b/source/blender/draw/engines/overlay/overlay_extra.c index 9d478310104..738ea5dd8e7 100644 --- a/source/blender/draw/engines/overlay/overlay_extra.c +++ b/source/blender/draw/engines/overlay/overlay_extra.c @@ -1315,6 +1315,8 @@ static void OVERLAY_relationship_lines(OVERLAY_ExtraCallBuffers *cb, if ((curcon->ui_expand_flag & (1 << 0)) && BKE_constraint_targets_get(curcon, &targets)) { bConstraintTarget *ct; + BKE_constraint_custom_object_space_init(cob, curcon); + for (ct = targets.first; ct; ct = ct->next) { /* calculate target's matrix */ if (cti->get_target_matrix) { diff --git a/source/blender/editors/transform/transform_mode.c b/source/blender/editors/transform/transform_mode.c index 5ba0f08ee1c..356828f513f 100644 --- a/source/blender/editors/transform/transform_mode.c +++ b/source/blender/editors/transform/transform_mode.c @@ -292,6 +292,9 @@ void constraintTransLim(const TransInfo *t, TransData *td) continue; } + /* Initialize the custom space for use in calculating the matrices. */ + BKE_constraint_custom_object_space_init(&cob, con); + /* get constraint targets if needed */ BKE_constraint_targets_for_solving_get(t->depsgraph, con, &cob, &targets, ctime); |