Radiant GI is a screen space effect. It provides instant global illumination, but it’s limited to the screen content. Non-visible objects (i.e. objects behind the camera or out of screen) can’t illuminate other objects in the scene. On the other hand, Radiant is 100% GPU based, requires no pre-computation, works with any kind of 3D scene including dynamic/procedural content and any surface or light, and it’s very easy to use.
To complement light data from off-screen objects, we’ve provided “fallbacks” methods. These fallbacks can be enabled in the Radiant GI inspector and are described here.
You can enable any number of fallbacks. Some are more expensive than others and the system will automatically pick the best one automatically.
This technique is very cheap and uses data from previous frames. When a ray misses a target during the main Radiant raytrace pass, it can look for rays from previous frames that were emitted from the same positions and reuse them. The result is a smoother GI composition.
The downside of this option is that it could add some ghosting or trails to fast moving objects so you may want to use a lower Intensity value for this fallback looking for a satisfying balance. Also, it’s still limited to in-screen surfaces.
Using Radiant GI with reflection probes
When using the reflection probes option in the Fallbacks section, Radiant GI will automatically use the cubemap rendered by nearby reflection probes when rays miss their target in screen space. Although this can’t be 100% accurate, it will improve the effect.
To use reflection probes with Radiant, add the “Radiant Probe” script to any number of reflection probes. Radiant will automatically use the 2 nearest reflection probes to the camera. Of course, this technique requires that you use reflection probes in the scene.
You can add a reflection probe as a child to the camera and make it real-time probe to provide the most accurate result possible although this will be quite expensive. Or just add reflection probes to the center of rooms with bake mode set to Awake.
Radiant GI will use the importance and intensity values of each reflection probes as well as the blending distance and boundaries defined by box size to determine the weight of the sampling of the probe cubemap texture.
Using Reflective Shadow Maps
This feature can be enabled in the Fallback section of Radiant GI inspector. When you enable this option, make sure the script “Radiant Shadow Map” is added to the main directional light.
Reflective Shadow Maps is a technique used to compute global illumination for certain lights. It works like shadow maps, but instead of capturing only the depth map from the light point of view, it also captures the emitted light (also called flux), the normals and world positions of those pixels. Using this data, the technique computes the bounces of the light onto nearby pixels or surfaces generating a GI map which is later used during the main step of Radiant GI.
The benefit of this technique is that it can supply GI data to Radiant GI for objects that are not within the camera frustum.
For optimization purposes, Radiant GI only computes the buffers (flux, normal, world positions) of the reflective shadow maps when the directional light rotates or when the camera position changes at least 5 meters.
Selection Criteria and Performance
If reflection probes are available, the system will always use their data. If they’re not available, it will try to use data from the reflective shadow maps. And finally, if no reflection probes or reflective shadow map data is available, it will use the “Reuse Rays” fallback (only if these fallbacks are enabled of course, you can decide which fallbacks can use the system).
- Reuse Rays: very fast.
- Reflection Probes: medium.
- Reflective Shadow Maps: expensive when it’s updated, but medium normally (it’s updated only when directional light rotates or camera moves a certain distance so while not updating,
Use fallbacks only if lighting changes are distracting or affecting your game experience. Please remember that Radiant GI or global illumination in general, can be used along other lighting effects. This means that Radiant GI should be used wisely, to make your scene better looking by adding a subtle extra lighting to it.
Regarding fallbacks, our recommendations are:
- Since ”Reuse Rays” fallback is very cheap, you should use it always, unless ghosting is an issue.
- Using Reflection Probes with at least one probe at the center of a room (or several if the room is big) with Bake mode = Awake at least, will provide light data from off-screen objects.
- If reflection probes can’t be used, reflective shadow maps can improve the results. In outdoors or large open areas for example, they can be a better alternative to reflection probes if the Sun is high in the sky (so the scene capture is as wide as possible – remember the RSM capture image data from the directional light point of view to account for shadows).