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>2022-08-23 13:40:26 +0300
committerJacques Lucke <jacques@blender.org>2022-08-23 13:40:26 +0300
commit1663530408fd0a9f3870289c225acedf24e014d9 (patch)
tree88f84d25f68bc171afa88a0a485ae78706844adf
parent95464a842cc19efa534d1dacd5fbe7cc5b9fcf52 (diff)
Fix T100318: handle custom nodes in field inferencing more gracefully
Custom nodes are not supported, but it shouldn't crash here.
-rw-r--r--source/blender/blenkernel/intern/node_tree_update.cc6
1 files changed, 6 insertions, 0 deletions
diff --git a/source/blender/blenkernel/intern/node_tree_update.cc b/source/blender/blenkernel/intern/node_tree_update.cc
index 5eb962337fa..58084226b00 100644
--- a/source/blender/blenkernel/intern/node_tree_update.cc
+++ b/source/blender/blenkernel/intern/node_tree_update.cc
@@ -94,6 +94,9 @@ static InputSocketFieldType get_interface_input_field_type(const NodeRef &node,
if (node.is_undefined()) {
return InputSocketFieldType::None;
}
+ if (node.bnode()->type == NODE_CUSTOM) {
+ return InputSocketFieldType::None;
+ }
const NodeDeclaration *node_decl = node.declaration();
@@ -131,6 +134,9 @@ static OutputFieldDependency get_interface_output_field_dependency(const NodeRef
if (node.is_undefined()) {
return OutputFieldDependency::ForDataSource();
}
+ if (node.bnode()->type == NODE_CUSTOM) {
+ return OutputFieldDependency::ForDataSource();
+ }
const NodeDeclaration *node_decl = node.declaration();