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>2020-11-27 21:38:14 +0300
committerJacques Lucke <jacques@blender.org>2020-11-27 21:38:14 +0300
commit659ef4938b9be1f45575d1958bb149ab8066273d (patch)
tree291980fba0c01c399ef5a1aa461259853df4147c /source/blender/nodes/NOD_node_tree_ref.hh
parent683041fd488d06721e2169e2134c7dacd6bb80f6 (diff)
Geometry Nodes: support muted nodes
The handling of muted nodes is handled at the derived node tree level now. This is also where expanding node groups is handled. Muted nodes are relinked and removed from the derived tree during construction. The geometry node evaluation code does not have to know about muted nodes this way.
Diffstat (limited to 'source/blender/nodes/NOD_node_tree_ref.hh')
-rw-r--r--source/blender/nodes/NOD_node_tree_ref.hh6
1 files changed, 6 insertions, 0 deletions
diff --git a/source/blender/nodes/NOD_node_tree_ref.hh b/source/blender/nodes/NOD_node_tree_ref.hh
index ebdd8b7fe49..7fcc117ba93 100644
--- a/source/blender/nodes/NOD_node_tree_ref.hh
+++ b/source/blender/nodes/NOD_node_tree_ref.hh
@@ -153,6 +153,7 @@ class NodeRef : NonCopyable, NonMovable {
bool is_group_node() const;
bool is_group_input_node() const;
bool is_group_output_node() const;
+ bool is_muted() const;
};
class NodeTreeRef : NonCopyable, NonMovable {
@@ -402,6 +403,11 @@ inline bool NodeRef::is_group_output_node() const
return bnode_->type == NODE_GROUP_OUTPUT;
}
+inline bool NodeRef::is_muted() const
+{
+ return (bnode_->flag & NODE_MUTED) != 0;
+}
+
/* --------------------------------------------------------------------
* NodeRef inline methods.
*/