|
Blender V5.3
|
Functions | |
| float | diffuse_sphere_integral (sampler2DArray util_tx, float avg_dir_z, float form_factor) |
| float3 | solve_cubic (float4 coefs) |
| float3 | edge_integral_vec (float3 v1, float3 v2) |
| float | upper_parabole (float x, float scale, float y_1) |
| float3 | dominant_bxdf_direction (float3x3 Minv) |
| float | form_factor_attenuation (LightShape shape, LTCData ltc_data, float3 L) |
| float eevee::ltc::detail::diffuse_sphere_integral | ( | sampler2DArray | util_tx, |
| float | avg_dir_z, | ||
| float | form_factor ) |
Diffuse clipped sphere integral. This should equal the irradiance (form factor) of a horizon-clipped sphere w.r.t. a single point. However, the form factor is divided out, resulting in a multiplier defining the clipped sphere only.
Definition at line 32 of file eevee_ltc_lib.bsl.hh.
References diffuse_sphere_integral(), max, texture(), UTIL_DISK_INTEGRAL_COMP, UTIL_DISK_INTEGRAL_LAYER, UTIL_TEX_UV_BIAS, and UTIL_TEX_UV_SCALE.
Referenced by diffuse_sphere_integral(), eevee::ltc::evaluate_disk(), and eevee::ltc::evaluate_quad().
Get the 3rd column of the inverse of 3x3 matrix M^{-1}, normalized. We can avoid computing the reciprocal determinant as we need a unit vector.
Definition at line 173 of file eevee_ltc_lib.bsl.hh.
References dominant_bxdf_direction(), and normalize.
Referenced by dominant_bxdf_direction(), and form_factor_attenuation().
Approximate edge integral as part of a polygon area integral over a cosine (hemi)sphere.
Definition at line 145 of file eevee_ltc_lib.bsl.hh.
References abs, b, cross, dot(), edge_integral_vec(), inversesqrt(), max, x, and y.
Referenced by edge_integral_vec(), and eevee::ltc::evaluate_quad().
| float eevee::ltc::detail::form_factor_attenuation | ( | LightShape | shape, |
| LTCData | ltc_data, | ||
| float3 | L ) |
Fitted function to attenuation light leakage caused by the sphere integral approximation.
Definition at line 184 of file eevee_ltc_lib.bsl.hh.
References abs, eevee::LTCData::attenuation_factor, D, LightShape::disk_radius_projected, dominant_bxdf_direction(), dot(), form_factor_attenuation(), L, min, eevee::LTCData::Minv, LightShape::N, normalize, normalize_fallback(), safe_divide(), saturate, square(), T, and upper_parabole().
Referenced by eevee::ltc::evaluate_disk(), eevee::ltc::evaluate_quad(), and form_factor_attenuation().
An extended version of the implementation from How to solve a cubic equation, revisited.
Definition at line 50 of file eevee_ltc_lib.bsl.hh.
References A, atan, B, C, clamp(), cos, D, dot(), F, FLT_MAX, G, M_PI, solve_cubic(), sqrt, float4::w, float2::x, float3::x, float4::x, float2::y, float3::y, float4::y, float3::z, and float4::z.
Referenced by eevee::ltc::evaluate_disk(), and solve_cubic().
Upper parabolic curve of the form x/(1+x), going through y_1 at x=1, with scale determining the curve shape.
Definition at line 163 of file eevee_ltc_lib.bsl.hh.
References saturate, scale(), upper_parabole(), and x.
Referenced by form_factor_attenuation(), and upper_parabole().