40 if (
STREQ(socket_out_->name,
"Is Camera Ray")) {
43 if (
STREQ(socket_out_->name,
"Ray Length")) {
46 NodeItem res = val(0.0f);
64 "Retrieve the type of incoming ray for which the shader is being executed.\nTypically used "
65 "for non-physically-based tricks";
68 ntype.
declare = file_ns::node_declare;
69 ntype.
gpu_fn = file_ns::node_shader_gpu_light_path;
#define SH_NODE_LIGHT_PATH
bool GPU_stack_link(GPUMaterial *mat, const bNode *node, const char *name, GPUNodeStack *in, GPUNodeStack *out,...)
void node_register_type(bNodeType &ntype)
static void node_declare(NodeDeclarationBuilder &b)
static int node_shader_gpu_light_path(GPUMaterial *mat, bNode *node, bNodeExecData *, GPUNodeStack *in, GPUNodeStack *out)
#define NODE_SHADER_MATERIALX_BEGIN
#define NODE_SHADER_MATERIALX_END
void register_node_type_sh_light_path()
void sh_node_type_base(blender::bke::bNodeType *ntype, std::string idname, const std::optional< int16_t > legacy_type)
NodeMaterialXFunction materialx_fn
std::string ui_description
NodeGPUExecFunction gpu_fn
const char * enum_name_legacy
NodeDeclareFunction declare