Thanks for the patch. The two proposed alternatives require the same amount of memory (16 bytes more compared to the version with union
), but with variant
the intention of the code is clearer…
Hi, I don't think 17c8e0d309 caused the issue. The light tree uses a bit trail with int
type, which limits the tree depth to a maximum of 32, so it is expected that it will fail when dealing…
Shouldn't it be MAP_PASS(..., true)
instead of false
? It was originally PassMode::NOISY
.
Thanks for investigating.
I'm a bit worried about code duplication. I guess you can move the angle wrapping in sky_texture_precompute_nishita()
to shader.cpp
instead, just before `sky->set_su…
This array stores indices of the build-in lights (area light, spot light, sun light, point light), these lights are often called "lamps" throughout the code. Besides that we have mesh lights, which are kept in a separate array called mesh_to_light
. Because both types are called "lights", I thought it would be less confusing to rename the other one to lamp_to_tree
.