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:
authorJacques Lucke <jacques@blender.org>2021-04-22 13:49:34 +0300
committerJacques Lucke <jacques@blender.org>2021-04-22 13:49:34 +0300
commit8c146d5efc693e695f986e11a7e91b9508c6fee1 (patch)
treedbcdd50f63e002f65b4f778395b75a9898d9bfac
parent1095d5964dd259df8e013a686060ffd82c97c6ab (diff)
parent71db02ed887d8b9db958b482aa42cc27f0e57ed2 (diff)
Merge branch 'blender-v2.93-release'
-rw-r--r--source/blender/modifiers/intern/MOD_nodes.cc15
1 files changed, 13 insertions, 2 deletions
diff --git a/source/blender/modifiers/intern/MOD_nodes.cc b/source/blender/modifiers/intern/MOD_nodes.cc
index 53b79d0b2a5..57de629fc18 100644
--- a/source/blender/modifiers/intern/MOD_nodes.cc
+++ b/source/blender/modifiers/intern/MOD_nodes.cc
@@ -271,6 +271,17 @@ static bool isDisabled(const struct Scene *UNUSED(scene),
return false;
}
+static bool logging_enabled(const ModifierEvalContext *ctx)
+{
+ if (!DEG_is_active(ctx->depsgraph)) {
+ return false;
+ }
+ if ((ctx->flag & MOD_APPLY_ORCO) != 0) {
+ return false;
+ }
+ return true;
+}
+
class GeometryNodesEvaluator {
public:
using LogSocketValueFn = std::function<void(DSocket, Span<GPointer>)>;
@@ -1290,7 +1301,7 @@ static GeometrySet compute_geometry(const DerivedNodeTree &tree,
find_sockets_to_preview(nmd, ctx, tree, preview_sockets);
auto log_socket_value = [&](const DSocket socket, const Span<GPointer> values) {
- if (!DEG_is_active(ctx->depsgraph)) {
+ if (!logging_enabled(ctx)) {
return;
}
Span<uint64_t> keys = preview_sockets.lookup(socket);
@@ -1401,7 +1412,7 @@ static void modifyGeometry(ModifierData *md,
return;
}
- if (DEG_is_active(ctx->depsgraph)) {
+ if (logging_enabled(ctx)) {
reset_tree_ui_storage(tree.used_node_tree_refs(), *ctx->object, *md);
}