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:
authorPhilipp Oeser <info@graphics-engineer.com>2019-03-15 18:15:37 +0300
committerPhilipp Oeser <info@graphics-engineer.com>2019-03-15 20:49:13 +0300
commit9ad9d38786c5d9f3e7f288f2e8255f3e7722da1f (patch)
treefa8a2f18e8eb7569946cd05f68bd6954a975afb4 /source/blender
parentbc8bd87dfffe44cd5b9053800f086704ff880f6a (diff)
Fix T62601: parenting to curve (follow path) causes offset
Similar to T60623 / rB2894e75121d7. Issue (when parenting with 'Follow Curve') is that the curves CU_FOLLOW flag is set on the original, but not the evaluated curve (yet), leading to misbehaviour in 'ob_parcurve()'. Setting this on both now. Reviewers: sergey Maniphest Tasks: T62601 Differential Revision: https://developer.blender.org/D4524
Diffstat (limited to 'source/blender')
-rw-r--r--source/blender/editors/object/object_relations.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/source/blender/editors/object/object_relations.c b/source/blender/editors/object/object_relations.c
index dbd90628136..95d1ddea7f3 100644
--- a/source/blender/editors/object/object_relations.c
+++ b/source/blender/editors/object/object_relations.c
@@ -628,14 +628,16 @@ bool ED_object_parent_set(ReportList *reports, const bContext *C, Scene *scene,
return 0;
else {
Curve *cu = par->data;
-
+ Curve *cu_eval = parent_eval->data;
if ((cu->flag & CU_PATH) == 0) {
cu->flag |= CU_PATH | CU_FOLLOW;
+ cu_eval->flag |= CU_PATH | CU_FOLLOW;
/* force creation of path data */
BKE_displist_make_curveTypes(depsgraph, scene, par, false, false, NULL);
}
else {
cu->flag |= CU_FOLLOW;
+ cu_eval->flag |= CU_FOLLOW;
}
/* if follow, add F-Curve for ctime (i.e. "eval_time") so that path-follow works */