mirror of
https://github.com/bevyengine/bevy.git
synced 2026-05-06 06:06:42 -04:00
128450bdcc
# Objective Adds initial support for rectangle area lights, closing #7662. Implements Linearly Transformed Cosines ([Heitz et al, 2016](https://eheitzresearch.wordpress.com/415-2/)), with some tricks from [these slides](https://advances.realtimerendering.com/s2016/s2016_ltc_rnd.pdf) and [the reference implementation](https://github.com/selfshadow/ltc_code). ## Limitations There's currently no support for: - Anisotropic materials (there's [a follow-up paper](https://aakashkt.github.io/ltc_anisotropic.html) that shouldn't be too hard to implement on top of this, though) - Shadows - Textured lights - Clustering ## Testing - Compared results to eevee/cycles, see showcase section. - Ran the new example with `cargo run --example rect_light --features free_camera`, and made sure everythign works at grazing angles and from behind the light. - Clearcoat and transmission could probably use more testing, I just made sure nothing looked obviously broken. --- ## Showcase <img width="1919" height="941" alt="Showcase" src="https://github.com/user-attachments/assets/f506f05c-4869-4387-aeba-d16944497825" /> <img width="1919" height="941" alt="Screenshot From 2026-03-11 11-43-42" src="https://github.com/user-attachments/assets/c4a44903-784f-4c3e-bd44-84c3fe7bff29" /> Varying ground plane roughness: 