Commit Graph

4 Commits

Author SHA1 Message Date
1081fb472f 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>
2026-03-25 20:58:28 +09:00
080ac92fbb fix(renderer): merge IBL into group(3) to stay within max_bind_groups limit of 4
wgpu's default max_bind_groups is 4 (groups 0-3), but the PBR shader was
using group(4) for BRDF LUT bindings. This merges IBL bindings into the
shadow bind group (group 3) at binding slots 3-4, removes the standalone
IBL bind group layout/creation, and updates all examples accordingly.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-24 21:38:45 +09:00
8f962368e9 feat(renderer): integrate shadow map sampling with 3x3 PCF into PBR shader
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-24 21:03:31 +09:00
b5a6159526 feat(renderer): add ShadowMap, shadow depth shader, and shadow pipeline
Implements ShadowMap (2048x2048 Depth32Float texture with comparison sampler),
shadow_shader.wgsl (depth-only vertex shader), shadow_pipeline (front-face
culling, depth bias constant=2/slope=2.0), and associated uniform types.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-24 21:01:51 +09:00