20 #include "../node_shader_util.h"
26 {
SOCK_RGBA,
N_(
"Color"), 0.017513f, 0.005763f, 0.002059f, 1.0f, 0.0f, 1.0f},
29 {
SOCK_RGBA,
N_(
"Tint"), 1.0f, 1.0f, 1.0f, 1.0f, 0.0f, 1.0f},
30 {
SOCK_VECTOR,
N_(
"Absorption Coefficient"), 0.245531f, 0.52f, 1.365f, 0.0f, 0.0f, 1000.0f},
34 {
SOCK_FLOAT,
N_(
"IOR"), 1.55f, 0.0f, 0.0f, 0.0f, 0.0f, 1000.0f},
46 {
SOCK_FLOAT,
N_(
"Random"), 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 1.0f,
PROP_NONE,
SOCK_HIDE_VALUE},
65 int parametrization =
node->custom1;
67 for (sock =
node->inputs.first; sock; sock = sock->
next) {
84 else if (
STREQ(sock->
name,
"Melanin Redness")) {
100 else if (
STREQ(sock->
name,
"Absorption Coefficient")) {
108 else if (
STREQ(sock->
name,
"Random Color")) {
typedef float(TangentPoint)[2]
void node_type_socket_templates(struct bNodeType *ntype, struct bNodeSocketTemplate *inputs, struct bNodeSocketTemplate *outputs)
void node_type_update(struct bNodeType *ntype, void(*updatefunc)(struct bNodeTree *ntree, struct bNode *node))
void node_type_init(struct bNodeType *ntype, void(*initfunc)(struct bNodeTree *ntree, struct bNode *node))
void node_type_size_preset(struct bNodeType *ntype, eNodeSizePreset size)
void node_type_storage(struct bNodeType *ntype, const char *storagename, void(*freefunc)(struct bNode *node), void(*copyfunc)(struct bNodeTree *dest_ntree, struct bNode *dest_node, const struct bNode *src_node))
#define NODE_CLASS_SHADER
void nodeRegisterType(struct bNodeType *ntype)
#define SHD_PRINCIPLED_HAIR_DIRECT_ABSORPTION
#define SHD_PRINCIPLED_HAIR_REFLECTANCE
#define SHD_PRINCIPLED_HAIR_PIGMENT_CONCENTRATION
Group RGB to Bright Vector Camera Vector Combine Material Light Line Style Layer Add Ambient Diffuse Glossy Refraction Transparent Toon SH_NODE_BSDF_HAIR_PRINCIPLED
static bNodeSocketTemplate sh_node_bsdf_hair_principled_in[]
static void node_shader_update_hair_principled(bNodeTree *UNUSED(ntree), bNode *node)
void register_node_type_sh_bsdf_hair_principled(void)
static void node_shader_init_hair_principled(bNodeTree *UNUSED(ntree), bNode *node)
static bNodeSocketTemplate sh_node_bsdf_hair_principled_out[]
void sh_node_type_base(struct bNodeType *ntype, int type, const char *name, short nclass, short flag)
Compact definition of a node socket.
struct bNodeSocket * next