The Benefit of Light Probes in Unity
Unity’s light probes give us a performant way of achieving high quality lighting in our scenes. Essentially, light probes store (baked) information about light passing through empty space within our scene, with the probes themselves measuring light in given positions during the baking process. Then at runtime, if a dynamic/moving GameObject enters the bounds of these light probes, the values from from them will be used so that they appear correctly integrated with the surrounding light conditions.
***
This sort of thing definitely isn’t an area of expertise for me, but from my understanding we need to ‘bake’ or essentially pre-process as much of the expensive lighting calculations as we can, otherwise they can adversely effect runtime performance (particularly on lower-end devices and on mobile). If we tried to just bake all of the lighting in our scenes, this would be all well and good if none of the objects needed move. For a completely static and unshifting scene, we could easily calculate all of that information by creating ‘lightmaps’ for the objects in our scene. But if a ball comes rolling through, say, a shaded, pre-baked area, none of that shading information will be transferred onto the ball, and instead we’ll need to run a separate process to calculate the lighting that’s casting a shadow onto it.
To handle this in a more performant way, light probes offer a great compromise between runtime illumination and baked illumination, taking care of a lot of the heavy processing work when we hit bake. So while an elaborate network of light probes in our scenes can look quite overwhelming in the editor view, we’re really just using these to measure and record illumination in empty space:
Apologies that this article is a tad repetitious 😉 I’m trying to properly get my ahead around lighting and performance at the moment, so some of this is largely just to help the information sink in for me a bit more.