20 b.add_input<
decl::Color>(
"Image").default_value({0.8f, 0.8f, 0.8f, 1.0f});
39 static const mf::Signature
signature = []() {
41 mf::SignatureBuilder builder{
"Separate RGB",
signature};
43 builder.single_output<
float>(
"R");
44 builder.single_output<
float>(
"G");
45 builder.single_output<
float>(
"B");
83 ntype.
ui_name =
"Separate RGB (Legacy)";
87 ntype.
declare = file_ns::sh_node_seprgb_declare;
88 ntype.
gpu_fn = file_ns::gpu_shader_seprgb;
117 static auto fn = mf::build::SI3_SO<float, float, float, ColorGeometry4f>(
118 "Combine RGB", [](
float r,
float g,
float b) {
return ColorGeometry4f(r, g,
b, 1.0f); });
131 ntype.
ui_name =
"Combine RGB (Legacy)";
135 ntype.
declare = file_ns::sh_node_combrgb_declare;
136 ntype.
gpu_fn = file_ns::gpu_shader_combrgb;
#define NODE_CLASS_CONVERTER
#define SH_NODE_COMBRGB_LEGACY
#define SH_NODE_SEPRGB_LEGACY
#define BLT_I18NCONTEXT_COLOR
bool GPU_stack_link(GPUMaterial *mat, const bNode *node, const char *name, GPUNodeStack *in, GPUNodeStack *out,...)
const Signature & signature() const
void set_signature(const Signature *signature)
void set_matching_fn(const mf::MultiFunction *fn)
std::optional< std::string > translation_context
void call(const IndexMask &mask, mf::Params params, mf::Context) const override
ccl_device_inline float2 mask(const MaskType mask, const float2 a)
void node_register_type(bNodeType &ntype)
static int gpu_shader_combrgb(GPUMaterial *mat, bNode *node, bNodeExecData *, GPUNodeStack *in, GPUNodeStack *out)
static int gpu_shader_seprgb(GPUMaterial *mat, bNode *node, bNodeExecData *, GPUNodeStack *in, GPUNodeStack *out)
static void sh_node_combrgb_declare(NodeDeclarationBuilder &b)
static void sh_node_seprgb_build_multi_function(NodeMultiFunctionBuilder &builder)
static void sh_node_combrgb_build_multi_function(NodeMultiFunctionBuilder &builder)
static void sh_node_seprgb_declare(NodeDeclarationBuilder &b)
ColorSceneLinear4f< eAlpha::Premultiplied > ColorGeometry4f
void register_node_type_sh_seprgb()
void register_node_type_sh_combrgb()
void common_node_type_base(blender::bke::bNodeType *ntype, std::string idname, const std::optional< int16_t > legacy_type)
std::string ui_description
NodeGPUExecFunction gpu_fn
NodeMultiFunctionBuildFunction build_multi_function
const char * enum_name_legacy
NodeGatherSocketLinkOperationsFunction gather_link_search_ops
NodeDeclareFunction declare