24 .default_value(6500.0f)
50 static auto fn = mf::build::SI1_SO<float, ColorGeometry4f>(
"Blackbody", [](
float temperature) {
61 NodeItem temperature = get_input_value(
"Temperature", NodeItem::Type::Float);
63 NodeItem res = create_node(
"blackbody", NodeItem::Type::Color3);
64 res.set_input(
"temperature", temperature);
81 ntype.
ui_description =
"Convert a blackbody temperature to an RGB value";
84 ntype.
declare = file_ns::node_declare;
86 ntype.
gpu_fn = file_ns::node_shader_gpu_blackbody;
#define NODE_CLASS_CONVERTER
#define SH_NODE_BLACKBODY
void set_matching_fn(const mf::MultiFunction *fn)
void node_register_type(bNodeType &ntype)
static void sh_node_blackbody_build_multi_function(nodes::NodeMultiFunctionBuilder &builder)
static void node_declare(NodeDeclarationBuilder &b)
static int node_shader_gpu_blackbody(GPUMaterial *mat, bNode *node, bNodeExecData *, GPUNodeStack *in, GPUNodeStack *out)
bool GPU_stack_link(GPUMaterial *mat, const bNode *node, const char *name, GPUNodeStack *in, GPUNodeStack *out,...)
void * MEM_new_array_uninitialized(size_t len, size_t size, const char *str) ATTR_WARN_UNUSED_RESULT ATTR_ALLOC_SIZE(1
void register_node_type_sh_blackbody()
GPUNodeLink * GPU_color_band(GPUMaterial *mat, int size, float *pixels, float *r_row)
GPUNodeLink * GPU_constant(const float *num)
BMesh const char void * data
void IMB_colormanagement_blackbody_temperature_to_rgb(float r_dest[4], float value)
void IMB_colormanagement_blackbody_temperature_to_rgb_table(float *r_table, int width, float min, float max)
ColorSceneLinear4f< eAlpha::Premultiplied > ColorGeometry4f
void common_node_type_base(bke::bNodeType *ntype, UString idname, const std::optional< int16_t > legacy_type)
#define NODE_SHADER_MATERIALX_BEGIN
#define NODE_SHADER_MATERIALX_END
static constexpr int _160
NodeMaterialXFunction materialx_fn
std::string ui_description
NodeGPUExecFunction gpu_fn
NodeMultiFunctionBuildFunction build_multi_function
const char * enum_name_legacy
NodeDeclareFunction declare