Invert spotlight angle attenuation

Inverted the spotlight angle attenuation so a higher value results in
a dimmer light, this makes it more consistent with the distance
attenuation.

Also changed the way spotlighs are computed in SDFGI
and GIPorbes and GPU lightmapper, now it matches the falloff used in the scene rendering
code.
This commit is contained in:
jfons
2021-02-06 21:39:08 +01:00
parent 7bb7a3c4a7
commit 99e1ce0690
9 changed files with 54 additions and 44 deletions

View File

@ -54,8 +54,8 @@ class LightmapperRD : public Lightmapper {
float size;
float range;
float attenuation;
float spot_angle;
float spot_attenuation;
float cos_spot_angle;
float inv_spot_attenuation;
uint32_t static_bake;
uint32_t pad[3];