diff options
author | Sergey Sharybin <sergey.vfx@gmail.com> | 2018-04-16 17:17:03 +0300 |
---|---|---|
committer | Sergey Sharybin <sergey.vfx@gmail.com> | 2018-04-16 17:17:03 +0300 |
commit | cf95267456a0c4f988691ecc822c211ff7849c55 (patch) | |
tree | c5420c147d74f72c01c7369c1317ab4aa65c2da8 /source/blender/depsgraph | |
parent | 295ced9baa717a5c36ff0e32510b52b61e62377c (diff) | |
parent | 047950db7ccd9440b04fb4bff82844de764bd444 (diff) |
Merge branch 'master' into blender2.8
Diffstat (limited to 'source/blender/depsgraph')
-rw-r--r-- | source/blender/depsgraph/intern/builder/deg_builder_nodes.cc | 38 | ||||
-rw-r--r-- | source/blender/depsgraph/intern/builder/deg_builder_nodes.h | 1 |
2 files changed, 39 insertions, 0 deletions
diff --git a/source/blender/depsgraph/intern/builder/deg_builder_nodes.cc b/source/blender/depsgraph/intern/builder/deg_builder_nodes.cc index a5a28ce0a8c..92af811dab4 100644 --- a/source/blender/depsgraph/intern/builder/deg_builder_nodes.cc +++ b/source/blender/depsgraph/intern/builder/deg_builder_nodes.cc @@ -382,6 +382,43 @@ void DepsgraphNodeBuilder::end_build() } } +void DepsgraphNodeBuilder::build_id(ID* id) { + if (id == NULL) { + return; + } + switch (GS(id->name)) { + case ID_GR: + build_group((Group *)id); + break; + case ID_OB: + build_object(-1, (Object *)id, DEG_ID_LINKED_INDIRECTLY); + break; + case ID_NT: + build_nodetree((bNodeTree *)id); + break; + case ID_MA: + build_material((Material *)id); + break; + case ID_TE: + build_texture((Tex *)id); + break; + case ID_IM: + build_image((Image *)id); + break; + case ID_WO: + build_world((World *)id); + break; + case ID_MSK: + build_mask((Mask *)id); + break; + case ID_MC: + build_movieclip((MovieClip *)id); + break; + default: + fprintf(stderr, "Unhandled ID %s\n", id->name); + } +} + void DepsgraphNodeBuilder::build_group(Group *group) { if (built_map_.checkIsBuiltAndTag(group)) { @@ -698,6 +735,7 @@ void DepsgraphNodeBuilder::build_driver_variables(ID * id, FCurve *fcurve) LISTBASE_FOREACH (DriverVar *, dvar, &fcurve->driver->variables) { DRIVER_TARGETS_USED_LOOPER(dvar) { + build_id(dtar->id); build_driver_id_property(dtar->id, dtar->rna_path); } DRIVER_TARGETS_LOOPER_END diff --git a/source/blender/depsgraph/intern/builder/deg_builder_nodes.h b/source/blender/depsgraph/intern/builder/deg_builder_nodes.h index df94671b4c6..757cacc6050 100644 --- a/source/blender/depsgraph/intern/builder/deg_builder_nodes.h +++ b/source/blender/depsgraph/intern/builder/deg_builder_nodes.h @@ -157,6 +157,7 @@ struct DepsgraphNodeBuilder { const char *name = "", int name_tag = -1); + void build_id(ID* id); void build_view_layer(Scene *scene, ViewLayer *view_layer, eDepsNode_LinkedState_Type linked_state); |