Realtime GI not included in build (Unity 2021.2.0 Beta - HDRP)

Realtime GI works in the editor but not in a build. Happens 100% of the time.

Am I missing some new setting/option that needs to be enabled when creating a build with Realtime GI? Is this a bug, perhaps?

This has been present in all previous alpha versions of 2021.2. I’m using HDRP.

Previously, I was using 2019.4 LTS HDRP (with a little “hack” to the enlighten variable) with no problems.

Which 2021.2 version are you on exactly? There was a regression which disabled realtime GI updates introduced in 2021.2.0a14, but has since been fixed in 2021.2.0a19. I would suggest updating to 2021.2.0a19 and trying again.

Thanks for the quick reply!

I’m using 2021.2.0b1.3029. Everything works fine in the Unity editor, and I’m able to set Realtime Global Illumination in the Lighting panel, but when I build the project, and run it, there is no longer any realtime light bounce.

To reproduce:

  • Create a new project using HDRP.
  • Using the SampleScene, change the light mode of “Directional Light Sun” to Realtime.
  • Enable Realtime Global Illumination in the Lighting panel. (Disable Baked Global Illumination for faster lightmap generation)
  • Generate Lighting. (The Realtime GI of the sun should work fine at this point)
  • Build the project with the SampleScene.
  • Run the EXE. (At this point, the Realtime GI doesn’t work in-game for me).

If it helps:

I’m using Windows 10.
Building for Windows x64.
Using Auto Graphics API for Windows.
Graphics card is a Nividia GeForce GTX 1650.

Thanks again!

Also, I just noticed I’m getting these errors in the console when I build.

Not sure if it’s related.

is there like any documentation on how to use enlighten for realtime GI with HDRP? I only see stuff marked as “deprecated” everywhere.

Yes, horrible support of the Enlighten. Nothing fixed at all. Also it still reset all GI after exit and enter the editor, and you always need to rebuild it.

This looks like a bug. Could you please report it and paste the bug ID here afterwards? We’ll take a look.

The case ID is: 1346410

I also discovered another bug shortly after submitting this one: enabling/disabling the checkbox for Realtime Global Illumination in the Lighting panel doesn’t update the realtime lightmaps. I have a feeling this problem is related to the initial bug, and I filed another report for that:

The case ID is: 1346418

There’s some additional information regarding the problem on that second bug report. The lightmaps will update if you rapidly click the Realtime Global Illumination checkbox in the editor, but only when the scene has large realtime lightmaps to calculate.

I think MikkoK-HS is onto something in this thread: https://discussions.unity.com/t/837014

Thanks!

1 Like