diff options
Diffstat (limited to 'source/blender/nodes/composite/nodes/node_composite_texture.cc')
-rw-r--r-- | source/blender/nodes/composite/nodes/node_composite_texture.cc | 21 |
1 files changed, 12 insertions, 9 deletions
diff --git a/source/blender/nodes/composite/nodes/node_composite_texture.cc b/source/blender/nodes/composite/nodes/node_composite_texture.cc index eff008b4b41..5c2446d4f2c 100644 --- a/source/blender/nodes/composite/nodes/node_composite_texture.cc +++ b/source/blender/nodes/composite/nodes/node_composite_texture.cc @@ -25,28 +25,31 @@ /* **************** TEXTURE ******************** */ -namespace blender::nodes { +namespace blender::nodes::node_composite_texture_cc { static void cmp_node_texture_declare(NodeDeclarationBuilder &b) { - b.add_input<decl::Vector>("Offset").min(-2.0f).max(2.0f).subtype(PROP_TRANSLATION); - b.add_input<decl::Vector>("Scale") + b.add_input<decl::Vector>(N_("Offset")).min(-2.0f).max(2.0f).subtype(PROP_TRANSLATION); + b.add_input<decl::Vector>(N_("Scale")) .default_value({1.0f, 1.0f, 1.0f}) .min(-10.0f) .max(10.0f) .subtype(PROP_XYZ); - b.add_output<decl::Float>("Value"); - b.add_output<decl::Color>("Color"); + b.add_output<decl::Float>(N_("Value")); + b.add_output<decl::Color>(N_("Color")); } -} // namespace blender::nodes +} // namespace blender::nodes::node_composite_texture_cc -void register_node_type_cmp_texture(void) +void register_node_type_cmp_texture() { + namespace file_ns = blender::nodes::node_composite_texture_cc; + static bNodeType ntype; - cmp_node_type_base(&ntype, CMP_NODE_TEXTURE, "Texture", NODE_CLASS_INPUT, NODE_PREVIEW); - ntype.declare = blender::nodes::cmp_node_texture_declare; + cmp_node_type_base(&ntype, CMP_NODE_TEXTURE, "Texture", NODE_CLASS_INPUT); + ntype.declare = file_ns::cmp_node_texture_declare; + ntype.flag |= NODE_PREVIEW; nodeRegisterType(&ntype); } |