|
Blender V5.0
|
Go to the source code of this file.
| ccl_device void make_orthonormals_safe_tangent | ( | const float3 | N, |
| const float3 | T, | ||
| ccl_private float3 * | a, | ||
| ccl_private float3 * | b ) |
Definition at line 51 of file sample/mapping.h.
References b, ccl_device, ccl_private, cross, len_squared(), make_orthonormals(), N, safe_normalize(), and T.
Referenced by bsdf_sheen_setup().
| ccl_device void make_orthonormals_tangent | ( | const float3 | N, |
| const float3 | T, | ||
| ccl_private float3 * | a, | ||
| ccl_private float3 * | b ) |
Definition at line 42 of file sample/mapping.h.
References b, ccl_device, ccl_private, cross, N, normalize, and T.
Referenced by bsdf_ashikhmin_shirley_eval(), bsdf_ashikhmin_shirley_sample(), bsdf_microfacet_eval(), bsdf_microfacet_sample(), and compute_v().
| ccl_device_inline float pdf_cos_hemisphere | ( | const float3 | N, |
| const float3 | D ) |
Definition at line 82 of file sample/mapping.h.
References ccl_device_inline, cos_theta(), D, dot(), M_1_PI_F, and N.
Referenced by sphere_light_pdf(), and spot_light_pdf().
| ccl_device_inline Spectrum pdf_exponential_distribution | ( | const float | x, |
| const Spectrum | lambda, | ||
| const Interval< float > | t ) |
Definition at line 243 of file sample/mapping.h.
References ccl_device_inline, clamp(), exp, Interval< T >::max, Interval< T >::min, safe_divide(), and x.
| ccl_device_inline float pdf_uniform_cone | ( | const float3 | N, |
| const float3 | D, | ||
| const float | angle ) |
Definition at line 107 of file sample/mapping.h.
References angle(), ccl_device_inline, D, M_1_2PI_F, N, one_minus_cos(), precise_angle(), and z().
Referenced by background_sun_pdf().
| ccl_device float2 regular_polygon_sample | ( | const float | corners, |
| float | rotation, | ||
| const float2 | rand ) |
Definition at line 184 of file sample/mapping.h.
References angle(), ccl_device, cosf, floorf, M_PI_F, make_float2, sinf, sqrtf, v, float2::x, and float2::y.
Referenced by camera_sample_aperture().
| ccl_device_inline void sample_cos_hemisphere | ( | const float3 | N, |
| const float2 | rand_in, | ||
| ccl_private float3 * | wo, | ||
| ccl_private float * | pdf ) |
Definition at line 67 of file sample/mapping.h.
References B, ccl_device_inline, ccl_private, len_squared(), M_1_PI_F, make_orthonormals(), N, safe_sqrtf(), sample_uniform_disk(), T, float2::x, and float2::y.
Referenced by bsdf_diffuse_sample(), bsdf_oren_nayar_sample(), bsdf_translucent_sample(), point_light_sample(), and spot_light_sample().
| ccl_device_inline float sample_exponential_distribution | ( | const float | rand, |
| const float | lambda ) |
Definition at line 226 of file sample/mapping.h.
References ccl_device_inline, and logf.
| ccl_device_inline float sample_exponential_distribution | ( | const float | rand, |
| const float | lambda, | ||
| const Interval< float > | t ) |
Definition at line 235 of file sample/mapping.h.
References ccl_device_inline, clamp(), expf, logf, Interval< T >::max, and Interval< T >::min.
| ccl_device_inline int sample_geometric_distribution | ( | const float | rand, |
| const float | r, | ||
| ccl_private float & | pmf, | ||
| const int | cut_off = INT_MAX ) |
Definition at line 214 of file sample/mapping.h.
References ccl_device_inline, ccl_private, floorf, logf, min, and powf.
| ccl_device_inline float3 sample_uniform_cone | ( | const float3 | N, |
| const float | one_minus_cos_angle, | ||
| const float2 | rand, | ||
| ccl_private float * | cos_theta, | ||
| ccl_private float * | pdf ) |
Definition at line 121 of file sample/mapping.h.
References B, ccl_device_inline, ccl_private, cos_theta(), len_squared(), M_1_2PI_F, make_orthonormals(), N, safe_sqrtf(), sample_uniform_disk(), T, and xy.
Referenced by background_sun_sample(), bsdf_diffuse_toon_sample(), bsdf_glossy_toon_sample(), distant_light_sample(), point_light_sample(), and spot_light_sample().
| CCL_NAMESPACE_BEGIN ccl_device float2 sample_uniform_disk | ( | const float2 | rand | ) |
Definition at line 17 of file sample/mapping.h.
References b, ccl_device, M_PI_2_F, M_PI_4_F, polar_to_cartesian(), float2::x, float2::y, and zero_float2().
Referenced by bsdf_sheen_sample(), camera_sample_aperture(), ellipse_sample(), microfacet_ggx_sample_vndf(), sample_cos_hemisphere(), sample_uniform_cone(), and sample_uniform_hemisphere().
| ccl_device_inline void sample_uniform_hemisphere | ( | const float3 | N, |
| const float2 | rand, | ||
| ccl_private float3 * | wo, | ||
| ccl_private float * | pdf ) |
Definition at line 89 of file sample/mapping.h.
References B, ccl_device_inline, ccl_private, len_squared(), M_1_2PI_F, make_orthonormals(), N, safe_sqrtf(), sample_uniform_disk(), T, xy, and z().
Referenced by bsdf_ashikhmin_velvet_sample().
| ccl_device float3 sample_uniform_sphere | ( | const float2 | rand | ) |
Definition at line 174 of file sample/mapping.h.
References ccl_device, M_2PI_F, make_float3(), polar_to_cartesian(), sin_from_cos(), float2::x, float2::y, and z().
Referenced by background_light_sample(), point_light_sample(), and spot_light_sample().