I’m having issues with light probes and i’m looking for a few pointers to make sure this isn’t a bug or error on my part.
This is a closed room with a single Area Baked light inside of it.
Lightmaps bake correctly, any object marked static and Contribute GI look fine within the scene.
However after rigging up light probes and having the objects gather their lighting data from the probes, they are significantly darker. Specifically in lower lighting. The spheres are darker than the baked shadow portion of the room when using probes.
For comparison, baked with all Unity default Spheres marked as static:
I’ve tried a massive variation of light probe positions, watched countless tutorials to sanity check and read the unity literature on them. Still i run into this issue. Is there any known issue currently with Light Probes / Area lights / LWRP?
For testing purposes, here are two of the many Light Probe set ups i’ve been messing with. One, a minimal rig that creates new volumes where light is dramatically transitioning from light to shadow, and fills the bounds of the room.
Thanks for having a look, thefranke.
I’m using the Progressive GPU, however results are almost identical on both progressive CPU and GPU.
Enlighten has a slightly brighter hot spot, but the spheres are still darker than their baked surroundings in shadow.
Bakes from each option and their settings; GPU: CPU: ENLIGHTEN:
I’d imagine people could be curious about the ambient colour being full black in this set up.
The results are the same regardless of the environmental lighting options. Darker than surrounding baked shadows. Darker than they would be if baked as static.
Example:
If i can provide any more info to pick this apart, let me know.
Ah, it seems to be related to whether the project is using Gamma or Linear colour space.
In a standard 3D template, 2019.2.10f1 - WebGL target platform:
Linear colour space - light probes give accurate results.
Gamma - light probes give accurate results.
In a LWRP template, 2019.2.10f1 - WebGL target platform:
(testing both WebGL 1.0 and 2.0 graphic API’s)
Linear - light probes give accurate results. Gamma - light probes give darker results.
Is this expected behaviour? Do lightprobes in LWRP fail to give accurate results in Gamma colour space for some reason?
Last time i checked, Linear colour space is unsupported in OpenGLES2 (WebGL 1.0).
Some major browsers, ie; Safari and Edge only have partial support for WebGL 2.0. Testing Linear colour space and the OpenGLES3 API gave errors in these browsers and failed to load the content. So this project is restricted to WebGL 1.0 and Gamma colour space.
Looks like LWRP is a no-go for WebGL 1.0 or Gamma colour space currently?
After a bit more testing, this appears to happen with all light sources. It’s not specific to just area lights.
It also happens in 2019.1. Not just specific to 2019.2
2019.3 has an alternative sampling algorithm you can use if you enable it in the editor (I think?) settings, although I think it mostly changes the amount of samples taken so probably shouldn’t affect the above test scenes, but it’s worth a try.
some more question: Which mode do you use for baking, Indirect or Shadowmask? The spheres in the Gamma picture appear slightly brighter than those in the original picture in your first post. In the first probe picture you posted, the spheres in the shadowed portion on the left seem to gather no indirect light at all. Can you perhaps create a screenshot like the Gamma view with all sphere’s lightmapped?
Hi thefranke, thanks for taking another look at this.
I’m pretty sure all previous tests were done with Subtractive Baked GI.
Here are some more accurate images testing all combinations in your questions. I’ll have to split the post into two to get around the file upload limit.
Firstly the setup:
16 Unity primitive spheres, equidistant, inside a room made of Unity primitive cubes.
Area light is used in these images, but other testing shows all light types produce similar results.
The Light probe component is a grid of equidistant probes. As shown here:
Lightmapper properties and lighting values are consistent across every bake test, and shown in the images below.
All lighting results below are in Gamma colour space.
To bake? They were all Sub 20 second bakes for this scene.
Just quickly timing it now, there is no discernible difference between Baked Indirect or Subtractive in this scene. But it is a simple scene, so i’m not sure if this indicates much.