Changeset View
Changeset View
Standalone View
Standalone View
source/blender/nodes/composite/nodes/node_composite_common.cc
| Show All 26 Lines | void register_node_type_cmp_group() | ||||
| ntype.poll_instance = node_group_poll_instance; | ntype.poll_instance = node_group_poll_instance; | ||||
| ntype.insert_link = node_insert_link_default; | ntype.insert_link = node_insert_link_default; | ||||
| ntype.rna_ext.srna = RNA_struct_find("CompositorNodeGroup"); | ntype.rna_ext.srna = RNA_struct_find("CompositorNodeGroup"); | ||||
| BLI_assert(ntype.rna_ext.srna != nullptr); | BLI_assert(ntype.rna_ext.srna != nullptr); | ||||
| RNA_struct_blender_type_set(ntype.rna_ext.srna, &ntype); | RNA_struct_blender_type_set(ntype.rna_ext.srna, &ntype); | ||||
| node_type_size(&ntype, 140, 60, 400); | node_type_size(&ntype, 140, 60, 400); | ||||
| ntype.labelfunc = node_group_label; | ntype.labelfunc = node_group_label; | ||||
| ntype.group_update_func = node_group_update; | ntype.declare_dynamic = blender::nodes::node_group_declare_dynamic; | ||||
| nodeRegisterType(&ntype); | nodeRegisterType(&ntype); | ||||
| } | } | ||||
| void register_node_type_cmp_custom_group(bNodeType *ntype) | void register_node_type_cmp_custom_group(bNodeType *ntype) | ||||
| { | { | ||||
| /* These methods can be overridden but need a default implementation otherwise. */ | /* These methods can be overridden but need a default implementation otherwise. */ | ||||
| if (ntype->poll == nullptr) { | if (ntype->poll == nullptr) { | ||||
| ntype->poll = cmp_node_poll_default; | ntype->poll = cmp_node_poll_default; | ||||
| } | } | ||||
| if (ntype->insert_link == nullptr) { | if (ntype->insert_link == nullptr) { | ||||
| ntype->insert_link = node_insert_link_default; | ntype->insert_link = node_insert_link_default; | ||||
| } | } | ||||
| } | } | ||||