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:
authorSergey Sharybin <sergey@blender.org>2022-09-12 17:30:07 +0300
committerSergey Sharybin <sergey@blender.org>2022-09-13 12:00:37 +0300
commitbb3a021427f2132f1db62a76eeca2ca4be1601da (patch)
tree0532c51e51801104721b5d6204e8d2943c55c273 /source/blender/depsgraph/intern/depsgraph_tag.cc
parenta45c36efae07f22dd1da1ebac728324aeafce85e (diff)
Fix T101004: Crash when invisible object becomes visible
A regression since ac20970bc208 The issue was caused by depsgraph clearing all id->recalc flags wrongly assuming that all IDs are fully evaluated. This change makes it so the depsgraph becomes aware of possibly incompletely evaluated IDs. Differential Revision: https://developer.blender.org/D15946
Diffstat (limited to 'source/blender/depsgraph/intern/depsgraph_tag.cc')
-rw-r--r--source/blender/depsgraph/intern/depsgraph_tag.cc7
1 files changed, 7 insertions, 0 deletions
diff --git a/source/blender/depsgraph/intern/depsgraph_tag.cc b/source/blender/depsgraph/intern/depsgraph_tag.cc
index cc742b98866..a8c8b4a6538 100644
--- a/source/blender/depsgraph/intern/depsgraph_tag.cc
+++ b/source/blender/depsgraph/intern/depsgraph_tag.cc
@@ -890,6 +890,13 @@ void DEG_ids_clear_recalc(Depsgraph *depsgraph, const bool backup)
}
/* Go over all ID nodes, clearing tags. */
for (deg::IDNode *id_node : deg_graph->id_nodes) {
+ if (!id_node->is_enabled_on_eval) {
+ id_node->id_invisible_recalc |= id_node->id_cow->recalc;
+ }
+ else {
+ id_node->id_invisible_recalc = 0;
+ }
+
if (backup) {
id_node->id_cow_recalc_backup |= id_node->id_cow->recalc;
}