Changeset View
Changeset View
Standalone View
Standalone View
source/blender/nodes/composite/nodes/node_composite_sepcombRGBA.cc
| Show All 18 Lines | |||||
| /** \file | /** \file | ||||
| * \ingroup cmpnodes | * \ingroup cmpnodes | ||||
| */ | */ | ||||
| #include "node_composite_util.hh" | #include "node_composite_util.hh" | ||||
| /* **************** SEPARATE RGBA ******************** */ | /* **************** SEPARATE RGBA ******************** */ | ||||
| namespace blender::nodes { | namespace blender::nodes::node_cmp_seprgba_cc { | ||||
| static void cmp_node_seprgba_declare(NodeDeclarationBuilder &b) | static void cmp_node_seprgba_declare(NodeDeclarationBuilder &b) | ||||
| { | { | ||||
| b.add_input<decl::Color>(N_("Image")).default_value({1.0f, 1.0f, 1.0f, 1.0f}); | b.add_input<decl::Color>(N_("Image")).default_value({1.0f, 1.0f, 1.0f, 1.0f}); | ||||
| b.add_output<decl::Float>(N_("R")); | b.add_output<decl::Float>(N_("R")); | ||||
| b.add_output<decl::Float>(N_("G")); | b.add_output<decl::Float>(N_("G")); | ||||
| b.add_output<decl::Float>(N_("B")); | b.add_output<decl::Float>(N_("B")); | ||||
| b.add_output<decl::Float>(N_("A")); | b.add_output<decl::Float>(N_("A")); | ||||
| } | } | ||||
| } // namespace blender::nodes | } // namespace blender::nodes::node_cmp_seprgba_cc | ||||
| void register_node_type_cmp_seprgba(void) | void register_node_type_cmp_seprgba(void) | ||||
| { | { | ||||
| namespace file_ns = blender::nodes::node_cmp_seprgba_cc; | |||||
| static bNodeType ntype; | static bNodeType ntype; | ||||
| cmp_node_type_base(&ntype, CMP_NODE_SEPRGBA, "Separate RGBA", NODE_CLASS_CONVERTER, 0); | cmp_node_type_base(&ntype, CMP_NODE_SEPRGBA, "Separate RGBA", NODE_CLASS_CONVERTER, 0); | ||||
| ntype.declare = blender::nodes::cmp_node_seprgba_declare; | ntype.declare = file_ns::cmp_node_seprgba_declare; | ||||
| nodeRegisterType(&ntype); | nodeRegisterType(&ntype); | ||||
| } | } | ||||
| /* **************** COMBINE RGBA ******************** */ | /* **************** COMBINE RGBA ******************** */ | ||||
| namespace blender::nodes { | namespace blender::nodes::node_cmp_combrgba_cc { | ||||
| static void cmp_node_combrgba_declare(NodeDeclarationBuilder &b) | static void cmp_node_combrgba_declare(NodeDeclarationBuilder &b) | ||||
| { | { | ||||
| b.add_input<decl::Float>(N_("R")).min(0.0f).max(1.0f); | b.add_input<decl::Float>(N_("R")).min(0.0f).max(1.0f); | ||||
| b.add_input<decl::Float>(N_("G")).min(0.0f).max(1.0f); | b.add_input<decl::Float>(N_("G")).min(0.0f).max(1.0f); | ||||
| b.add_input<decl::Float>(N_("B")).min(0.0f).max(1.0f); | b.add_input<decl::Float>(N_("B")).min(0.0f).max(1.0f); | ||||
| b.add_input<decl::Float>(N_("A")).default_value(1.0f).min(0.0f).max(1.0f); | b.add_input<decl::Float>(N_("A")).default_value(1.0f).min(0.0f).max(1.0f); | ||||
| b.add_output<decl::Color>(N_("Image")); | b.add_output<decl::Color>(N_("Image")); | ||||
| } | } | ||||
| } // namespace blender::nodes | } // namespace blender::nodes::node_cmp_combrgba_cc | ||||
| void register_node_type_cmp_combrgba(void) | void register_node_type_cmp_combrgba(void) | ||||
| { | { | ||||
| namespace file_ns = blender::nodes::node_cmp_combrgba_cc; | |||||
| static bNodeType ntype; | static bNodeType ntype; | ||||
| cmp_node_type_base(&ntype, CMP_NODE_COMBRGBA, "Combine RGBA", NODE_CLASS_CONVERTER, 0); | cmp_node_type_base(&ntype, CMP_NODE_COMBRGBA, "Combine RGBA", NODE_CLASS_CONVERTER, 0); | ||||
| ntype.declare = blender::nodes::cmp_node_combrgba_declare; | ntype.declare = file_ns::cmp_node_combrgba_declare; | ||||
| nodeRegisterType(&ntype); | nodeRegisterType(&ntype); | ||||
| } | } | ||||