66 template<u
int node_feature_mask, ShaderType shader_type>
74 uint type, param1_offset, param2_offset;
76 uint mix_weight_offset;
107 #ifdef __PRINCIPLED__
109 uint specular_offset, roughness_offset, specular_tint_offset, anisotropic_offset,
110 sheen_offset, sheen_tint_offset, clearcoat_offset, clearcoat_roughness_offset,
111 eta_offset, transmission_offset, anisotropic_rotation_offset,
112 transmission_roughness_offset;
119 &specular_tint_offset,
120 &anisotropic_offset);
125 &clearcoat_roughness_offset);
128 &transmission_offset,
129 &anisotropic_rotation_offset,
130 &transmission_roughness_offset);
134 float subsurface = param2;
142 float clearcoat_roughness =
stack_load_float(stack, clearcoat_roughness_offset);
144 float anisotropic_rotation =
stack_load_float(stack, anisotropic_rotation_offset);
145 float transmission_roughness =
stack_load_float(stack, transmission_roughness_offset);
152 if (anisotropic_rotation != 0.0f)
159 float cosNO =
dot(
N, sd->I);
166 float specular_weight = (1.0f - final_transmission);
189 float subsurface_anisotropy =
stack_valid(data_cn_ssr.
w) ?
203 # ifdef __SUBSURFACE__
204 float3 mixed_ss_base_color = subsurface_color * subsurface +
205 base_color * (1.0f - subsurface);
206 float3 subsurf_weight = weight * mixed_ss_base_color * diffuse_weight;
217 base_color = mixed_ss_base_color;
223 float3 diff_weight = weight * base_color * diffuse_weight;
240 bssrdf->radius = subsurface_radius * subsurface;
241 bssrdf->albedo = mixed_ss_base_color;
246 subsurface_ior =
clamp(subsurface_ior, 1.01f, 3.8f);
247 bssrdf->anisotropy =
clamp(subsurface_anisotropy, 0.0f, 0.9f);
257 float3 diff_weight = weight * base_color * diffuse_weight;
275 float3 m_ctint = m_cdlum > 0.0f ?
276 base_color / m_cdlum :
281 m_ctint * sheen_tint;
283 float3 sheen_weight = weight * sheen * sheen_color * diffuse_weight;
297 # ifdef __CAUSTICS_TRICKS__
302 float3 spec_weight = weight * specular_weight;
317 float aspect =
safe_sqrtf(1.0f - anisotropic * 0.9f);
320 bsdf->alpha_x = r2 / aspect;
321 bsdf->alpha_y = r2 * aspect;
323 float m_cdlum = 0.3f * base_color.
x + 0.6f * base_color.
y +
325 float3 m_ctint = m_cdlum > 0.0f ?
326 base_color / m_cdlum :
330 m_ctint * specular_tint;
334 bsdf->extra->color = base_color;
335 bsdf->extra->clearcoat = 0.0f;
345 # ifdef __CAUSTICS_TRICKS__
350 # ifdef __CAUSTICS_TRICKS__
355 float3 glass_weight = weight * final_transmission;
356 float3 cspec0 = base_color * specular_tint +
357 make_float3(1.0f, 1.0f, 1.0f) * (1.0f - specular_tint);
364 # ifdef __CAUSTICS_TRICKS__
380 bsdf->alpha_x = refl_roughness * refl_roughness;
381 bsdf->alpha_y = refl_roughness * refl_roughness;
384 bsdf->extra->color = base_color;
385 bsdf->extra->cspec0 = cspec0;
386 bsdf->extra->clearcoat = 0.0f;
394 # ifdef __CAUSTICS_TRICKS__
399 float refraction_fresnel =
fmaxf(0.0001f, 1.0f - fresnel);
401 sd,
sizeof(
MicrofacetBsdf), base_color * glass_weight * refraction_fresnel);
408 transmission_roughness = 1.0f - (1.0f - refl_roughness) *
409 (1.0f - transmission_roughness);
411 transmission_roughness = refl_roughness;
413 bsdf->alpha_x = transmission_roughness * transmission_roughness;
414 bsdf->alpha_y = transmission_roughness * transmission_roughness;
439 bsdf->extra->color = base_color;
440 bsdf->extra->cspec0 = cspec0;
441 bsdf->extra->clearcoat = 0.0f;
448 # ifdef __CAUSTICS_TRICKS__
453 # ifdef __CAUSTICS_TRICKS__
465 bsdf->N = clearcoat_normal;
470 bsdf->alpha_x = clearcoat_roughness * clearcoat_roughness;
471 bsdf->alpha_y = clearcoat_roughness * clearcoat_roughness;
473 bsdf->extra->color =
make_float3(0.0f, 0.0f, 0.0f);
474 bsdf->extra->cspec0 =
make_float3(0.04f, 0.04f, 0.04f);
481 # ifdef __CAUSTICS_TRICKS__
529 #ifdef __CAUSTICS_TRICKS__
557 if (rotation != 0.0f)
561 float anisotropy =
clamp(param2, -0.99f, 0.99f);
562 if (anisotropy < 0.0f) {
563 bsdf->alpha_x =
roughness / (1.0f + anisotropy);
564 bsdf->alpha_y =
roughness * (1.0f + anisotropy);
567 bsdf->alpha_x =
roughness * (1.0f - anisotropy);
568 bsdf->alpha_y =
roughness / (1.0f - anisotropy);
585 bsdf->extra->cspec0 =
make_float3(0.0f, 0.0f, 0.0f);
586 bsdf->extra->clearcoat = 0.0f;
599 #ifdef __CAUSTICS_TRICKS__
612 float eta =
fmaxf(param2, 1e-5f);
617 bsdf->alpha_x = 0.0f;
618 bsdf->alpha_y = 0.0f;
641 #ifdef __CAUSTICS_TRICKS__
650 float eta =
fmaxf(param2, 1e-5f);
654 float cosNO =
dot(
N, sd->I);
659 #ifdef __CAUSTICS_TRICKS__
675 #ifdef __CAUSTICS_TRICKS__
680 float refraction_fresnel =
fmaxf(0.0001f, 1.0f - fresnel);
695 #ifdef __CAUSTICS_TRICKS__
720 float eta =
fmaxf(param2, 1e-5f);
725 bsdf->extra->cspec0 =
make_float3(0.0f, 0.0f, 0.0f);
726 bsdf->extra->clearcoat = 0.0f;
746 #ifdef __CAUSTICS_TRICKS__
759 bsdf->smooth = param2;
776 uint offset_ofs, ior_ofs, color_ofs, parametrization;
781 uint coat_ofs, melanin_ofs, melanin_redness_ofs, absorption_coefficient_ofs;
785 &melanin_redness_ofs,
786 &absorption_coefficient_ofs);
788 uint tint_ofs, random_ofs, random_color_ofs, random_roughness_ofs;
790 data_node3.
x, &tint_ofs, &random_ofs, &random_color_ofs, &random_roughness_ofs);
812 stack, random_roughness_ofs, data_node3.
w);
813 float factor_random_roughness = 1.0f + 2.0f * (
random - 0.5f) * random_roughness;
814 float roughness = param1 * factor_random_roughness;
815 float radial_roughness = param2 * factor_random_roughness;
819 float m0_roughness = 1.0f -
clamp(coat, 0.0f, 1.0f);
823 bsdf->s = radial_roughness;
824 bsdf->m0_roughness = m0_roughness;
829 switch (parametrization) {
832 bsdf->sigma = absorption_coefficient;
838 stack, melanin_redness_ofs, data_node2.
w);
842 random_color =
clamp(random_color, 0.0f, 1.0f);
843 float factor_random_color = 1.0f + 2.0f * (
random - 0.5f) * random_color;
844 melanin *= factor_random_color;
847 melanin = -
logf(
fmaxf(1.0f - melanin, 0.0001f));
850 float eumelanin = melanin * (1.0f - melanin_redness);
851 float pheomelanin = melanin * melanin_redness;
860 bsdf->sigma = melanin_sigma + tint_sigma;
876 sd->flag |= bsdf_principled_hair_setup(sd, bsdf);
889 bsdf->roughness1 = param1;
890 bsdf->roughness2 = param2;
915 #ifdef __SUBSURFACE__
930 bssrdf->albedo = sd->svm_closure_weight;
932 bssrdf->roughness = FLT_MAX;
934 const float subsurface_ior =
clamp(param2, 1.01f, 3.8f);
936 bssrdf->anisotropy =
clamp(subsurface_anisotropy, 0.0f, 0.9f);
951 template<ShaderType shader_type>
963 uint type, density_offset, anisotropy_offset;
965 uint mix_weight_offset;
979 float3 weight = sd->svm_closure_weight;
993 float anisotropy = (
stack_valid(anisotropy_offset)) ?
996 volume->g = anisotropy;
1006 template<ShaderType shader_type>
1023 uint density_offset, anisotropy_offset, absorption_color_offset, mix_weight_offset;
1025 node.y, &density_offset, &anisotropy_offset, &absorption_color_offset, &mix_weight_offset);
1034 float primitive_density = 1.0f;
1043 primitive_density = primitive_volume_attribute_float(kg, sd, attr_density);
1054 color *= primitive_volume_attribute_float3(kg, sd, attr_color);
1061 float anisotropy = (
stack_valid(anisotropy_offset)) ?
1064 volume->g = anisotropy;
1082 uint emission_offset, emission_color_offset, blackbody_offset, temperature_offset;
1084 node.z, &emission_offset, &emission_color_offset, &blackbody_offset, &temperature_offset);
1101 float temperature = primitive_volume_attribute_float(kg, sd, attr_temperature);
1102 T *=
fmaxf(temperature, 0.0f);
1109 float sigma = 5.670373e-8f * 1e-6f /
M_PI_F;
1110 float intensity = sigma *
mix(1.0f,
T4, blackbody);
1114 float3 bb = blackbody_tint * intensity *
1128 float3 weight = sd->svm_closure_weight;
1147 float3 weight = sd->svm_closure_weight;
1186 sd->svm_closure_weight = weight;
1223 uint weight_offset, in_weight_offset, weight1_offset, weight2_offset;
1225 node.y, &weight_offset, &in_weight_offset, &weight1_offset, &weight2_offset);
MINLINE float safe_sqrtf(float a)
_GL_VOID GLfloat value _GL_VOID_RET _GL_VOID const GLuint GLboolean *residences _GL_BOOL_RET _GL_VOID GLsizei GLfloat GLfloat GLfloat GLfloat const GLubyte *bitmap _GL_VOID_RET _GL_VOID GLenum const void *lists _GL_VOID_RET _GL_VOID const GLdouble *equation _GL_VOID_RET _GL_VOID GLdouble GLdouble blue _GL_VOID_RET _GL_VOID GLfloat GLfloat blue _GL_VOID_RET _GL_VOID GLint GLint blue _GL_VOID_RET _GL_VOID GLshort GLshort blue _GL_VOID_RET _GL_VOID GLubyte GLubyte blue _GL_VOID_RET _GL_VOID GLuint GLuint blue _GL_VOID_RET _GL_VOID GLushort GLushort blue _GL_VOID_RET _GL_VOID GLbyte GLbyte GLbyte alpha _GL_VOID_RET _GL_VOID GLdouble GLdouble GLdouble alpha _GL_VOID_RET _GL_VOID GLfloat GLfloat GLfloat alpha _GL_VOID_RET _GL_VOID GLint GLint GLint alpha _GL_VOID_RET _GL_VOID GLshort GLshort GLshort alpha _GL_VOID_RET _GL_VOID GLubyte GLubyte GLubyte alpha _GL_VOID_RET _GL_VOID GLuint GLuint GLuint alpha _GL_VOID_RET _GL_VOID GLushort GLushort GLushort alpha _GL_VOID_RET _GL_VOID GLenum mode _GL_VOID_RET _GL_VOID GLint GLsizei GLsizei GLenum type _GL_VOID_RET _GL_VOID GLsizei GLenum GLenum const void *pixels _GL_VOID_RET _GL_VOID const void *pointer _GL_VOID_RET _GL_VOID GLdouble v _GL_VOID_RET _GL_VOID GLfloat v _GL_VOID_RET _GL_VOID GLint GLint i2 _GL_VOID_RET _GL_VOID GLint j _GL_VOID_RET _GL_VOID GLfloat param _GL_VOID_RET _GL_VOID GLint param _GL_VOID_RET _GL_VOID GLdouble GLdouble GLdouble GLdouble GLdouble zFar _GL_VOID_RET _GL_UINT GLdouble *equation _GL_VOID_RET _GL_VOID GLenum GLint *params _GL_VOID_RET _GL_VOID GLenum GLfloat *v _GL_VOID_RET _GL_VOID GLenum GLfloat *params _GL_VOID_RET _GL_VOID GLfloat *values _GL_VOID_RET _GL_VOID GLushort *values _GL_VOID_RET _GL_VOID GLenum GLfloat *params _GL_VOID_RET _GL_VOID GLenum GLdouble *params _GL_VOID_RET _GL_VOID GLenum GLint *params _GL_VOID_RET _GL_VOID GLsizei const void *pointer _GL_VOID_RET _GL_VOID GLsizei const void *pointer _GL_VOID_RET _GL_BOOL GLfloat param _GL_VOID_RET _GL_VOID GLint param _GL_VOID_RET _GL_VOID GLenum GLfloat param _GL_VOID_RET _GL_VOID GLenum GLint param _GL_VOID_RET _GL_VOID GLushort pattern _GL_VOID_RET _GL_VOID GLdouble GLdouble GLint GLint const GLdouble *points _GL_VOID_RET _GL_VOID GLdouble GLdouble GLint GLint GLdouble GLdouble GLint GLint const GLdouble *points _GL_VOID_RET _GL_VOID GLdouble GLdouble u2 _GL_VOID_RET _GL_VOID GLdouble GLdouble GLint GLdouble GLdouble v2 _GL_VOID_RET _GL_VOID GLenum GLfloat param _GL_VOID_RET _GL_VOID GLenum GLint param _GL_VOID_RET _GL_VOID GLenum mode _GL_VOID_RET _GL_VOID GLdouble GLdouble nz _GL_VOID_RET _GL_VOID GLfloat GLfloat nz _GL_VOID_RET _GL_VOID GLint GLint nz _GL_VOID_RET _GL_VOID GLshort GLshort nz _GL_VOID_RET _GL_VOID GLsizei const void *pointer _GL_VOID_RET _GL_VOID GLsizei const GLfloat *values _GL_VOID_RET _GL_VOID GLsizei const GLushort *values _GL_VOID_RET _GL_VOID GLint param _GL_VOID_RET _GL_VOID const GLuint const GLclampf *priorities _GL_VOID_RET _GL_VOID GLdouble y _GL_VOID_RET _GL_VOID GLfloat y _GL_VOID_RET _GL_VOID GLint y _GL_VOID_RET _GL_VOID GLshort y _GL_VOID_RET _GL_VOID GLdouble GLdouble z _GL_VOID_RET _GL_VOID GLfloat GLfloat z _GL_VOID_RET _GL_VOID GLint GLint z _GL_VOID_RET _GL_VOID GLshort GLshort z _GL_VOID_RET _GL_VOID GLdouble GLdouble GLdouble w _GL_VOID_RET _GL_VOID GLfloat GLfloat GLfloat w _GL_VOID_RET _GL_VOID GLint GLint GLint w _GL_VOID_RET _GL_VOID GLshort GLshort GLshort w _GL_VOID_RET _GL_VOID GLdouble GLdouble GLdouble y2 _GL_VOID_RET _GL_VOID GLfloat GLfloat GLfloat y2 _GL_VOID_RET _GL_VOID GLint GLint GLint y2 _GL_VOID_RET _GL_VOID GLshort GLshort GLshort y2 _GL_VOID_RET _GL_VOID GLdouble GLdouble GLdouble z _GL_VOID_RET _GL_VOID GLdouble GLdouble z _GL_VOID_RET _GL_VOID GLuint *buffer _GL_VOID_RET _GL_VOID GLdouble t _GL_VOID_RET _GL_VOID GLfloat t _GL_VOID_RET _GL_VOID GLint t _GL_VOID_RET _GL_VOID GLshort t _GL_VOID_RET _GL_VOID GLdouble GLdouble r _GL_VOID_RET _GL_VOID GLfloat GLfloat r _GL_VOID_RET _GL_VOID GLint GLint r _GL_VOID_RET _GL_VOID GLshort GLshort r _GL_VOID_RET _GL_VOID GLdouble GLdouble r
_GL_VOID GLfloat value _GL_VOID_RET _GL_VOID const GLuint GLboolean *residences _GL_BOOL_RET _GL_VOID GLsizei GLfloat GLfloat GLfloat GLfloat const GLubyte *bitmap _GL_VOID_RET _GL_VOID GLenum type
static float mix_weight(float weight, float weight2, char mix_mode)
Group Output data from inside of a node group A color picker Mix two input colors RGB to Convert a color s luminance to a grayscale value Generate a normal vector and a dot product Bright Control the brightness and contrast of the input color Vector Map an input vectors to used to fine tune the interpolation of the input Camera Retrieve information about the camera and how it relates to the current shading point s position Clamp a value between a minimum and a maximum Vector Perform vector math operation Invert a producing a negative Combine Generate a color from its and blue Hue Saturation Apply a color transformation in the HSV color model Specular Similar to the Principled BSDF node but uses the specular workflow instead of metallic
Group Output data from inside of a node group A color picker Mix two input colors RGB to Convert a color s luminance to a grayscale value Generate a normal vector and a dot product Bright Control the brightness and contrast of the input color Vector Map an input vectors to used to fine tune the interpolation of the input Camera Retrieve information about the camera and how it relates to the current shading point s position Clamp a value between a minimum and a maximum Vector Perform vector math operation Invert a producing a negative Combine Generate a color from its and blue Hue Saturation Apply a color transformation in the HSV color model Specular BSDF
Group Output data from inside of a node group A color picker Mix two input colors RGB to Convert a color s luminance to a grayscale value Generate a normal vector and a dot product Bright Control the brightness and contrast of the input color Vector Map an input vectors to used to fine tune the interpolation of the input Camera Retrieve information about the camera and how it relates to the current shading point s position Clamp a value between a minimum and a maximum Vector Perform vector math operation Invert a color
CCL_NAMESPACE_BEGIN ccl_device ccl_private ShaderClosure * closure_alloc(ccl_private ShaderData *sd, int size, ClosureType type, float3 weight)
ccl_device ccl_private void * closure_alloc_extra(ccl_private ShaderData *sd, int size)
ccl_device_inline ccl_private ShaderClosure * bsdf_alloc(ccl_private ShaderData *sd, int size, float3 weight)
CCL_NAMESPACE_BEGIN ccl_device int bsdf_ashikhmin_shirley_setup(ccl_private MicrofacetBsdf *bsdf)
ccl_device int bsdf_ashikhmin_velvet_setup(ccl_private VelvetBsdf *bsdf)
ccl_device int bsdf_translucent_setup(ccl_private DiffuseBsdf *bsdf)
ccl_device int bsdf_diffuse_setup(ccl_private DiffuseBsdf *bsdf)
ccl_device int bsdf_hair_reflection_setup(ccl_private HairBsdf *bsdf)
ccl_device int bsdf_hair_transmission_setup(ccl_private HairBsdf *bsdf)
ccl_device_inline float3 bsdf_principled_hair_sigma_from_concentration(const float eumelanin, const float pheomelanin)
ccl_device_inline float3 bsdf_principled_hair_sigma_from_reflectance(const float3 color, const float azimuthal_roughness)
ccl_device int bsdf_microfacet_beckmann_setup(ccl_private MicrofacetBsdf *bsdf)
ccl_device int bsdf_microfacet_ggx_fresnel_setup(ccl_private MicrofacetBsdf *bsdf, ccl_private const ShaderData *sd)
ccl_device int bsdf_microfacet_ggx_clearcoat_setup(ccl_private MicrofacetBsdf *bsdf, ccl_private const ShaderData *sd)
ccl_device int bsdf_microfacet_beckmann_refraction_setup(ccl_private MicrofacetBsdf *bsdf)
ccl_device int bsdf_microfacet_ggx_setup(ccl_private MicrofacetBsdf *bsdf)
ccl_device int bsdf_microfacet_ggx_refraction_setup(ccl_private MicrofacetBsdf *bsdf)
ccl_device int bsdf_microfacet_multi_ggx_glass_fresnel_setup(ccl_private MicrofacetBsdf *bsdf, ccl_private const ShaderData *sd)
ccl_device int bsdf_microfacet_multi_ggx_setup(ccl_private MicrofacetBsdf *bsdf)
ccl_device int bsdf_microfacet_multi_ggx_glass_setup(ccl_private MicrofacetBsdf *bsdf)
ccl_device int bsdf_microfacet_multi_ggx_fresnel_setup(ccl_private MicrofacetBsdf *bsdf, ccl_private const ShaderData *sd)
ccl_device int bsdf_oren_nayar_setup(ccl_private OrenNayarBsdf *bsdf)
ccl_device int bsdf_principled_diffuse_setup(ccl_private PrincipledDiffuseBsdf *bsdf)
@ PRINCIPLED_DIFFUSE_FULL
ccl_device int bsdf_principled_sheen_setup(ccl_private const ShaderData *sd, ccl_private PrincipledSheenBsdf *bsdf)
CCL_NAMESPACE_BEGIN ccl_device int bsdf_reflection_setup(ccl_private MicrofacetBsdf *bsdf)
CCL_NAMESPACE_BEGIN ccl_device int bsdf_refraction_setup(ccl_private MicrofacetBsdf *bsdf)
ccl_device int bsdf_diffuse_toon_setup(ccl_private ToonBsdf *bsdf)
ccl_device int bsdf_glossy_toon_setup(ccl_private ToonBsdf *bsdf)
CCL_NAMESPACE_BEGIN ccl_device void bsdf_transparent_setup(ccl_private ShaderData *sd, const float3 weight, uint32_t path_flag)
ccl_device float3 ensure_valid_reflection(float3 Ng, float3 I, float3 N)
ccl_device float fresnel_dielectric_cos(float cosi, float eta)
ccl_device_inline ccl_private Bssrdf * bssrdf_alloc(ccl_private ShaderData *sd, float3 weight)
ccl_device int bssrdf_setup(ccl_private ShaderData *sd, ccl_private Bssrdf *bssrdf, ClosureType type, const float ior)
ccl_device_noinline void svm_node_emission_weight(KernelGlobals kg, ccl_private ShaderData *sd, ccl_private float *stack, uint4 node)
ccl_device_noinline void svm_node_mix_closure(ccl_private ShaderData *sd, ccl_private float *stack, uint4 node)
ccl_device void svm_node_set_normal(KernelGlobals kg, ccl_private ShaderData *sd, ccl_private float *stack, uint in_direction, uint out_normal)
ccl_device_noinline void svm_node_closure_background(ccl_private ShaderData *sd, ccl_private float *stack, uint4 node)
ccl_device_noinline void svm_node_closure_volume(KernelGlobals kg, ccl_private ShaderData *sd, ccl_private float *stack, uint4 node)
ccl_device void svm_node_closure_weight(ccl_private ShaderData *sd, ccl_private float *stack, uint weight_offset)
ccl_device_noinline int svm_node_principled_volume(KernelGlobals kg, ccl_private ShaderData *sd, ccl_private float *stack, uint4 node, uint32_t path_flag, int offset)
ccl_device void svm_node_closure_set_weight(ccl_private ShaderData *sd, uint r, uint g, uint b)
ccl_device_noinline int svm_node_closure_bsdf(KernelGlobals kg, ccl_private ShaderData *sd, ccl_private float *stack, uint4 node, uint32_t path_flag, int offset)
ccl_device_noinline void svm_node_closure_emission(ccl_private ShaderData *sd, ccl_private float *stack, uint4 node)
CCL_NAMESPACE_BEGIN ccl_device void svm_node_glass_setup(ccl_private ShaderData *sd, ccl_private MicrofacetBsdf *bsdf, int type, float eta, float roughness, bool refract)
ccl_device_noinline void svm_node_closure_holdout(ccl_private ShaderData *sd, ccl_private float *stack, uint4 node)
ccl_device_inline int svm_node_closure_bsdf_skip(KernelGlobals kg, int offset, uint type)
ccl_device_inline void svm_node_closure_store_weight(ccl_private ShaderData *sd, float3 weight)
#define kernel_assert(cond)
#define ccl_device_inline
#define ccl_device_noinline
#define CCL_NAMESPACE_END
const KernelGlobalsCPU *ccl_restrict KernelGlobals
CCL_NAMESPACE_BEGIN ccl_device void background_setup(ccl_private ShaderData *sd, const float3 weight)
ccl_device void emission_setup(ccl_private ShaderData *sd, const float3 weight)
IMETHOD void random(Vector &a)
addDelta operator for displacement rotational velocity.
IconTextureDrawCall normal
ccl_device int volume_henyey_greenstein_setup(ccl_private HenyeyGreensteinVolume *volume)
CCL_NAMESPACE_BEGIN ccl_device void volume_extinction_setup(ccl_private ShaderData *sd, float3 weight)
ccl_gpu_kernel_postfix ccl_global float int int int int float bool int offset
ccl_device_inline AttributeDescriptor find_attribute(KernelGlobals kg, ccl_private const ShaderData *sd, uint id)
ccl_device_inline void stack_store_float3(ccl_private float *stack, uint a, float3 f)
CCL_NAMESPACE_BEGIN ccl_device_inline float3 stack_load_float3(ccl_private float *stack, uint a)
ccl_device_inline uint4 read_node(KernelGlobals kg, ccl_private int *offset)
ccl_device_inline float stack_load_float_default(ccl_private float *stack, uint a, uint value)
ccl_device_inline void stack_store_float(ccl_private float *stack, uint a, float f)
ccl_device_inline float stack_load_float(ccl_private float *stack, uint a)
ccl_device_forceinline void svm_unpack_node_uchar4(uint i, ccl_private uint *x, ccl_private uint *y, ccl_private uint *z, ccl_private uint *w)
ccl_device_inline bool stack_valid(uint a)
@ NODE_PRINCIPLED_HAIR_REFLECTANCE
@ NODE_PRINCIPLED_HAIR_DIRECT_ABSORPTION
@ NODE_PRINCIPLED_HAIR_PIGMENT_CONCENTRATION
#define SVM_STACK_INVALID
@ CLOSURE_BSDF_MICROFACET_GGX_REFRACTION_ID
@ CLOSURE_VOLUME_HENYEY_GREENSTEIN_ID
@ CLOSURE_BSDF_ASHIKHMIN_SHIRLEY_ID
@ CLOSURE_BSSRDF_RANDOM_WALK_FIXED_RADIUS_ID
@ CLOSURE_BSDF_HAIR_PRINCIPLED_ID
@ CLOSURE_BSDF_MICROFACET_GGX_GLASS_ID
@ CLOSURE_BSDF_DIFFUSE_ID
@ CLOSURE_BSSRDF_BURLEY_ID
@ CLOSURE_BSDF_PRINCIPLED_ID
@ CLOSURE_BSDF_TRANSPARENT_ID
@ CLOSURE_BSDF_DIFFUSE_TOON_ID
@ CLOSURE_BSDF_MICROFACET_GGX_ID
@ CLOSURE_BSDF_MICROFACET_BECKMANN_REFRACTION_ID
@ CLOSURE_BSDF_MICROFACET_MULTI_GGX_ID
@ CLOSURE_BSDF_HAIR_TRANSMISSION_ID
@ CLOSURE_BSDF_SHARP_GLASS_ID
@ CLOSURE_BSDF_MICROFACET_BECKMANN_GLASS_ID
@ CLOSURE_BSSRDF_RANDOM_WALK_ID
@ CLOSURE_BSDF_REFRACTION_ID
@ CLOSURE_BSDF_MICROFACET_BECKMANN_ID
@ CLOSURE_BSDF_MICROFACET_MULTI_GGX_GLASS_ID
@ CLOSURE_BSDF_GLOSSY_TOON_ID
@ CLOSURE_VOLUME_ABSORPTION_ID
@ CLOSURE_BSDF_HAIR_REFLECTION_ID
@ CLOSURE_BSDF_TRANSLUCENT_ID
@ CLOSURE_BSDF_REFLECTION_ID
@ CLOSURE_BSDF_ASHIKHMIN_VELVET_ID
#define CLOSURE_WEIGHT_CUTOFF
#define IF_KERNEL_NODES_FEATURE(feature)
@ PATH_RAY_DIFFUSE_ANCESTOR
ccl_device float3 rec709_to_rgb(KernelGlobals kg, float3 rec709)
ccl_device float linear_rgb_to_gray(KernelGlobals kg, float3 c)
ccl_device_inline float average(const float2 &a)
ccl_device_inline float3 refract(const float3 incident, const float3 normal, const float eta)
ccl_device float3 svm_math_blackbody_color_rec709(float t)
T dot(const vec_base< T, Size > &a, const vec_base< T, Size > &b)
T clamp(const T &a, const T &min, const T &max)
vec_base< T, Size > normalize(const vec_base< T, Size > &v)
static const pxr::TfToken clearcoat("clearcoat", pxr::TfToken::Immortal)
static const pxr::TfToken b("b", pxr::TfToken::Immortal)
static const pxr::TfToken ior("ior", pxr::TfToken::Immortal)
static const pxr::TfToken g("g", pxr::TfToken::Immortal)
static const pxr::TfToken density("density", pxr::TfToken::Immortal)
static const pxr::TfToken roughness("roughness", pxr::TfToken::Immortal)
static const pxr::TfToken specular("specular", pxr::TfToken::Immortal)
CCL_NAMESPACE_BEGIN ccl_device_forceinline float primitive_surface_attribute_float(KernelGlobals kg, ccl_private const ShaderData *sd, const AttributeDescriptor desc, ccl_private float *dx, ccl_private float *dy)
closure color absorption() BUILTIN
closure color bssrdf(string method, normal N, vector radius, color albedo) BUILTIN
ccl_device_inline float __uint_as_float(uint i)
ccl_device_inline float sqr(float a)
ccl_device_inline float saturatef(float a)
ccl_device_inline float3 rotate_around_axis(float3 p, float3 axis, float angle)