Blender
V3.3
|
#include "kernel/integrator/path_state.h"
#include "kernel/integrator/shader_eval.h"
#include "kernel/light/light.h"
#include "kernel/sample/mapping.h"
#include "kernel/sample/mis.h"
Go to the source code of this file.
ccl_device_inline bool light_sample_is_light | ( | ccl_private const LightSample *ccl_restrict | ls | ) |
Definition at line 92 of file cycles/kernel/light/sample.h.
References LIGHT_BACKGROUND, and PRIM_NONE.
ccl_device_inline float light_sample_mis_weight_forward | ( | KernelGlobals | kg, |
const float | forward_pdf, | ||
const float | nee_pdf | ||
) |
Definition at line 285 of file cycles/kernel/light/sample.h.
References DIRECT_LIGHT_SAMPLING_FORWARD, DIRECT_LIGHT_SAMPLING_NEE, kernel_data, and power_heuristic().
Referenced by integrate_distant_lights(), integrate_light(), and integrator_eval_background_shader().
ccl_device_inline float light_sample_mis_weight_nee | ( | KernelGlobals | kg, |
const float | nee_pdf, | ||
const float | forward_pdf | ||
) |
Definition at line 301 of file cycles/kernel/light/sample.h.
References DIRECT_LIGHT_SAMPLING_FORWARD, DIRECT_LIGHT_SAMPLING_NEE, kernel_data, and power_heuristic().
CCL_NAMESPACE_BEGIN ccl_device_noinline_cpu float3 light_sample_shader_eval | ( | KernelGlobals | kg, |
IntegratorState | state, | ||
ccl_private ShaderData *ccl_restrict | emission_sd, | ||
ccl_private LightSample *ccl_restrict | ls, | ||
float | time | ||
) |
Definition at line 18 of file cycles/kernel/light/sample.h.
References ccl_global, kernel_data_fetch, LAMP_NONE, LIGHT_BACKGROUND, make_float3, NULL, PATH_RAY_EMISSION, PRIM_NONE, PROFILING_EVENT, PROFILING_INIT_FOR_SHADER, PROFILING_SHADE_LIGHT_EVAL, PROFILING_SHADE_LIGHT_SETUP, PROFILING_SHADER, shader_background_eval(), shader_constant_emission_eval(), shader_emissive_eval(), shader_setup_from_background(), shader_setup_from_sample(), state, time, and zero_float3().
Referenced by integrate_distant_lights(), and integrate_light().
ccl_device_inline bool light_sample_terminate | ( | KernelGlobals | kg, |
ccl_private const LightSample *ccl_restrict | ls, | ||
ccl_private BsdfEval *ccl_restrict | eval, | ||
const float | rand_terminate | ||
) |
Definition at line 99 of file cycles/kernel/light/sample.h.
References bsdf_eval_is_zero(), bsdf_eval_mul(), bsdf_eval_sum(), fabs(), kernel_data, and reduce_max().
ccl_device_inline void light_sample_to_surface_shadow_ray | ( | KernelGlobals | kg, |
ccl_private const ShaderData *ccl_restrict | sd, | ||
ccl_private const LightSample *ccl_restrict | ls, | ||
ccl_private Ray * | ray | ||
) |
Definition at line 263 of file cycles/kernel/light/sample.h.
References P(), shadow_ray_offset(), and shadow_ray_setup().
ccl_device_inline void light_sample_to_volume_shadow_ray | ( | KernelGlobals | kg, |
ccl_private const ShaderData *ccl_restrict | sd, | ||
ccl_private const LightSample *ccl_restrict | ls, | ||
const float3 | P, | ||
ccl_private Ray * | ray | ||
) |
Definition at line 275 of file cycles/kernel/light/sample.h.
References P(), and shadow_ray_setup().
ccl_device_inline float3 shadow_ray_offset | ( | KernelGlobals | kg, |
ccl_private const ShaderData *ccl_restrict | sd, | ||
float3 | L, | ||
ccl_private bool * | r_skip_self | ||
) |
Definition at line 182 of file cycles/kernel/light/sample.h.
References blender::math::clamp(), blender::math::dot(), kernel_data_fetch, L, NL, P(), PRIMITIVE_TRIANGLE, SHADER_SMOOTH_NORMAL, and shadow_ray_smooth_surface_offset().
Referenced by light_sample_to_surface_shadow_ray().
ccl_device_inline void shadow_ray_setup | ( | ccl_private const ShaderData *ccl_restrict | sd, |
ccl_private const LightSample *ccl_restrict | ls, | ||
const float3 | P, | ||
ccl_private Ray * | ray, | ||
const bool | skip_self | ||
) |
Definition at line 222 of file cycles/kernel/light/sample.h.
References differential_make_compact(), differential_zero_compact(), normalize_len(), OBJECT_NONE, P(), PRIM_NONE, SHADER_CAST_SHADOW, and zero_float3().
Referenced by light_sample_to_surface_shadow_ray(), and light_sample_to_volume_shadow_ray().
ccl_device_inline float3 shadow_ray_smooth_surface_offset | ( | KernelGlobals | kg, |
ccl_private const ShaderData *ccl_restrict | sd, | ||
float3 | Ng | ||
) |
Definition at line 127 of file cycles/kernel/light/sample.h.
References Freestyle::a, usdtokens::b(), Freestyle::c, blender::math::dot(), kernel_assert, max, min, motion_triangle_vertices_and_normals(), N, object_dir_transform(), P(), PRIMITIVE_MOTION_TRIANGLE, PRIMITIVE_TRIANGLE, SD_OBJECT_TRANSFORM_APPLIED, triangle_vertices_and_normals(), V, v, and w().
Referenced by shadow_ray_offset().