feat(renderer): improve IBL with Hosek-Wilkie sky, SH irradiance, GPU BRDF LUT

- Hosek-Wilkie inspired procedural sky (Rayleigh/Mie scattering, sun disk)
- L2 Spherical Harmonics irradiance (9 coefficients, CPU computation)
- SH evaluation in shader replaces sample_environment for diffuse IBL
- GPU compute BRDF LUT (Rg16Float, higher precision than CPU Rgba8Unorm)
- SkyParams (sun_direction, turbidity) in ShadowUniform

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-03-25 20:58:28 +09:00
parent abd6f5cf6e
commit 1081fb472f
13 changed files with 693 additions and 10 deletions

View File

@@ -42,6 +42,10 @@ struct ShadowUniform {
light_view_proj: mat4x4<f32>,
shadow_map_size: f32,
shadow_bias: f32,
_padding: vec2<f32>,
sun_direction: vec3<f32>,
turbidity: f32,
sh_coefficients: array<vec4<f32>, 7>,
};
@group(2) @binding(0) var t_shadow: texture_depth_2d;