From 863b7b3668fe67a082439181eaf49c3e94a87536 Mon Sep 17 00:00:00 2001 From: Sergey Sharybin Date: Tue, 4 Jun 2019 16:51:02 +0200 Subject: Depsgraph: Store recalc tag in ID->recalc Allows to have more granularity in checks compared to a node-factory based tagging in a generic tag/flush code. --- source/blender/depsgraph/intern/depsgraph_tag.cc | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'source/blender/depsgraph') diff --git a/source/blender/depsgraph/intern/depsgraph_tag.cc b/source/blender/depsgraph/intern/depsgraph_tag.cc index 2d4963e8fef..c2cc15460d1 100644 --- a/source/blender/depsgraph/intern/depsgraph_tag.cc +++ b/source/blender/depsgraph/intern/depsgraph_tag.cc @@ -578,6 +578,11 @@ void graph_id_tag_update( if (flag == 0) { deg_graph_node_tag_zero(bmain, graph, id_node, update_source); } + /* Store original flag in the ID. + * Allows to have more granularity than a node-factory based flags. */ + if (id_node != NULL) { + id_node->id_cow->recalc |= flag; + } int current_flag = flag; while (current_flag != 0) { IDRecalcFlag tag = (IDRecalcFlag)(1 << bitscan_forward_clear_i(¤t_flag)); -- cgit v1.2.3