diff options
author | Clément Foucault <foucault.clem@gmail.com> | 2022-01-12 14:49:36 +0300 |
---|---|---|
committer | Clément Foucault <foucault.clem@gmail.com> | 2022-01-12 14:50:02 +0300 |
commit | fb6bd8864411ee27db05ceadcb80f690f44e48dd (patch) | |
tree | 7f5354d1272612a32c28bfda4c03259970c402b7 /source/blender/depsgraph | |
parent | 46e049d0ce2bce2f53ddc41a0dbbea2969d00a5d (diff) |
Revert "BLI: Refactor vector types & functions to use templates"
Includes unwanted changes
This reverts commit 46e049d0ce2bce2f53ddc41a0dbbea2969d00a5d.
Diffstat (limited to 'source/blender/depsgraph')
-rw-r--r-- | source/blender/depsgraph/intern/builder/deg_builder_relations.cc | 11 | ||||
-rw-r--r-- | source/blender/depsgraph/intern/node/deg_node_factory.h | 2 |
2 files changed, 12 insertions, 1 deletions
diff --git a/source/blender/depsgraph/intern/builder/deg_builder_relations.cc b/source/blender/depsgraph/intern/builder/deg_builder_relations.cc index 1c09417e9ab..fcdc3fe58e8 100644 --- a/source/blender/depsgraph/intern/builder/deg_builder_relations.cc +++ b/source/blender/depsgraph/intern/builder/deg_builder_relations.cc @@ -1475,6 +1475,17 @@ void DepsgraphRelationBuilder::build_animation_images(ID *id) id, NodeType::IMAGE_ANIMATION, OperationCode::IMAGE_ANIMATION); TimeSourceKey time_src_key; add_relation(time_src_key, image_animation_key, "TimeSrc -> Image Animation"); + + /* The image users of these ids may change during evaluation. Make sure that the image + * animation update happens after evaluation. */ + if (GS(id->name) == ID_MA) { + OperationKey material_update_key(id, NodeType::SHADING, OperationCode::MATERIAL_UPDATE); + add_relation(material_update_key, image_animation_key, "Material Update -> Image Animation"); + } + else if (GS(id->name) == ID_WO) { + OperationKey world_update_key(id, NodeType::SHADING, OperationCode::WORLD_UPDATE); + add_relation(world_update_key, image_animation_key, "World Update -> Image Animation"); + } } } diff --git a/source/blender/depsgraph/intern/node/deg_node_factory.h b/source/blender/depsgraph/intern/node/deg_node_factory.h index 125f340a0fa..b3153a7ddfb 100644 --- a/source/blender/depsgraph/intern/node/deg_node_factory.h +++ b/source/blender/depsgraph/intern/node/deg_node_factory.h @@ -55,7 +55,7 @@ template<class ModeObjectType> struct DepsNodeFactoryImpl : public DepsNodeFacto void register_node_typeinfo(DepsNodeFactory *factory); /* Get typeinfo for specified type */ -DepsNodeFactory *type_get_factory(const NodeType type); +DepsNodeFactory *type_get_factory(NodeType type); } // namespace deg } // namespace blender |