10 b.add_input<
decl::Color>(
N_(
"Color")).default_value({1.0f, 1.0f, 1.0f, 1.0f});
16 b.add_input<
decl::Float>(
N_(
"IOR")).default_value(1.45f).min(0.0f).max(1000.0f);
34 GPU_link(mat,
"world_normals_get", &in[3].link);
38 GPU_link(mat,
"set_value_zero", &in[1].link);
void node_type_gpu(struct bNodeType *ntype, NodeGPUExecFunction gpu_fn)
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)
#define SH_NODE_BSDF_REFRACTION
#define NODE_CLASS_SHADER
void nodeRegisterType(struct bNodeType *ntype)
#define SHD_GLOSSY_BECKMANN
void GPU_material_flag_set(GPUMaterial *mat, eGPUMaterialFlag flag)
bool GPU_link(GPUMaterial *mat, const char *name,...)
bool GPU_stack_link(GPUMaterial *mat, struct bNode *node, const char *name, GPUNodeStack *in, GPUNodeStack *out,...)
static int node_shader_gpu_bsdf_refraction(GPUMaterial *mat, bNode *node, bNodeExecData *UNUSED(execdata), GPUNodeStack *in, GPUNodeStack *out)
static void node_declare(NodeDeclarationBuilder &b)
static void node_shader_init_refraction(bNodeTree *UNUSED(ntree), bNode *node)
static const pxr::TfToken out("out", pxr::TfToken::Immortal)
static const pxr::TfToken b("b", pxr::TfToken::Immortal)
void register_node_type_sh_bsdf_refraction()
void sh_node_type_base(struct bNodeType *ntype, int type, const char *name, short nclass)
NodeDeclareFunction declare