diff options
author | Sergey Sharybin <sergey.vfx@gmail.com> | 2017-10-20 17:15:30 +0300 |
---|---|---|
committer | Sergey Sharybin <sergey.vfx@gmail.com> | 2017-10-20 17:15:30 +0300 |
commit | cdd1e86499a31938d6e139ea091c4ec576ec8173 (patch) | |
tree | 6610280bd1ef9047316e4a72ac4fff315e11db14 /source/blender/editors/object/object_relations.c | |
parent | 0fdc0f8bbddf2913e784f4abc75972c76cabcc3a (diff) |
Fix/workaround wrong dependency graph being constructed after creating a proxy
Diffstat (limited to 'source/blender/editors/object/object_relations.c')
-rw-r--r-- | source/blender/editors/object/object_relations.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/source/blender/editors/object/object_relations.c b/source/blender/editors/object/object_relations.c index 839f8094c43..05739a2dec0 100644 --- a/source/blender/editors/object/object_relations.c +++ b/source/blender/editors/object/object_relations.c @@ -375,6 +375,15 @@ static int make_proxy_exec(bContext *C, wmOperator *op) BKE_object_make_proxy(newob, ob, gob); + /* Set back pointer immediately so dependency graph knows that this is + * is a proxy and will act accordingly. Otherwise correctness of graph + * will depend on order of bases. + * + * TODO(sergey): We really need to get rid of this bi-directional links + * in proxies with something like static overrides. + */ + newob->proxy->proxy_from = newob; + /* depsgraph flushes are needed for the new data */ DEG_relations_tag_update(bmain); DEG_id_tag_update(&newob->id, OB_RECALC_OB | OB_RECALC_DATA | OB_RECALC_TIME); |