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-07-26 13:11:54 +0300
committerSergey Sharybin <sergey@blender.org>2022-07-27 11:19:42 +0300
commit4dd409a185e2211e541479d6a878b17d5c7e2bdf (patch)
treefdf84c5e29c1f79cc165b0faa9a199b258c0d0d3 /source/blender/depsgraph/intern/eval/deg_eval.cc
parentd706d0460c5721e2b07f18ab6354754267628130 (diff)
Fix T99976: Animated visibility not rendering properly in viewport
A mistake in the 0dcee6a3866 which made specific driven visibility to work, but did not properly handle actual time-based visibility. The basic idea of the change is to preserve recalculation flags of nodes which were tagged for update but were not evaluated due to visibility constraints. In the file from the report this makes it so tagging which is done first time ID is in the dependency graph are handled when the ID actually becomes visible. This is what solved the root of the problem from the report: there was missing geometry update since it was "swallowed" by the evaluation during the object being invisible. In other configurations this change allows to handle pending geometry updates due to animated modifiers be handled when object becomes visible without time change. This change also solves visibility issue of the synchronization component which also started to be handled badly since the previous fix attempt. Basically, the needed exception in its visibility handling did not happen and a regular logic was used for it. Tested with files from the T99733, T99976, and from the Heist project. Differential Revision: https://developer.blender.org/D15544
Diffstat (limited to 'source/blender/depsgraph/intern/eval/deg_eval.cc')
-rw-r--r--source/blender/depsgraph/intern/eval/deg_eval.cc5
1 files changed, 3 insertions, 2 deletions
diff --git a/source/blender/depsgraph/intern/eval/deg_eval.cc b/source/blender/depsgraph/intern/eval/deg_eval.cc
index 89e1f1add18..9b2ce2bb707 100644
--- a/source/blender/depsgraph/intern/eval/deg_eval.cc
+++ b/source/blender/depsgraph/intern/eval/deg_eval.cc
@@ -111,7 +111,8 @@ void evaluate_node(const DepsgraphEvalState *state, OperationNode *operation_nod
* times.
* This is a thread-safe modification as the node's flags are only read for a non-scheduled nodes
* and this node has been scheduled. */
- operation_node->flag &= ~DEPSOP_FLAG_NEEDS_UPDATE;
+ operation_node->flag &= ~(DEPSOP_FLAG_DIRECTLY_MODIFIED | DEPSOP_FLAG_NEEDS_UPDATE |
+ DEPSOP_FLAG_USER_MODIFIED);
}
void deg_task_run_func(TaskPool *pool, void *taskdata)
@@ -466,7 +467,7 @@ void deg_evaluate_on_refresh(Depsgraph *graph)
deg_eval_stats_aggregate(graph);
}
- /* Clear any uncleared tags - just in case. */
+ /* Clear any uncleared tags. */
deg_graph_clear_tags(graph);
graph->is_evaluating = false;