Blender  V3.3
node_geo_input_material_index.cc
Go to the documentation of this file.
1 /* SPDX-License-Identifier: GPL-2.0-or-later */
2 
3 #include "node_geometry_util.hh"
4 
6 
8 {
9  b.add_output<decl::Int>(N_("Material Index")).field_source();
10 }
11 
13 {
14  Field<int> material_index_field = AttributeFieldInput::Create<int>("material_index");
15  params.set_output("Material Index", std::move(material_index_field));
16 }
17 
18 } // namespace blender::nodes::node_geo_input_material_index_cc
19 
21 {
23 
24  static bNodeType ntype;
25 
29  nodeRegisterType(&ntype);
30 }
#define GEO_NODE_INPUT_MATERIAL_INDEX
Definition: BKE_node.h:1460
#define NODE_CLASS_INPUT
Definition: BKE_node.h:345
void nodeRegisterType(struct bNodeType *ntype)
Definition: node.cc:1357
uiWidgetBaseParameters params[MAX_WIDGET_BASE_BATCH]
static const pxr::TfToken b("b", pxr::TfToken::Immortal)
void register_node_type_geo_input_material_index()
void geo_node_type_base(bNodeType *ntype, int type, const char *name, short nclass)
Defines a node type.
Definition: BKE_node.h:226
NodeGeometryExecFunction geometry_node_execute
Definition: BKE_node.h:316
NodeDeclareFunction declare
Definition: BKE_node.h:324
#define N_(msgid)