Search Unity

Is there still no way to rebake the gi?

Discussion in 'Global Illumination' started by Amph1dian, May 6, 2022.

  1. Amph1dian

    Amph1dian

    Joined:
    Mar 14, 2020
    Posts:
    24
    I have looked through literally every thread discussing this topic, and every answer is "its not possible" or "use segi" (which is deprecated).

    So, for my specific problem. I'm making a game where the player traverses through a procedurally generated maze. So when the player gets near a wall, the maze generates more so you could walk infinitely. So after I did all of that, I wanted to make the game look decent, so I added lights to the roof of the maze and it looked even worse than before, because there was no global illumination. And since the maze is instantiated at runtime, I couldn't bake the lighting.

    Is there any way in hdrp to rebake the lighting? And before you say "use ssgi" I have already tried that and there was loads of lightning bugs and other stuff.

    Sidenote, I already know rtx works, but I don't have a card and it would slice the playerbase into 16ths.
     
  2. kristijonas_unity

    kristijonas_unity

    Unity Technologies

    Joined:
    Feb 8, 2018
    Posts:
    1,080
    I think you already know the answer to this question, because you've already answered it yourself. Sorry to disappoint you, but Lightmap baking in runtime is not supported. You would need to rely on realtime lighting.

    Alternatively, if you can separate your maze into separate scenes, you could rely on additive scene lighting to achieve what you are looking for. I'd recommend you check out this tutorial project on the Asset Store: https://assetstore.unity.com/packages/templates/tutorials/additive-loading-lighting-examples-129922
     
  3. Bordeaux_Fox

    Bordeaux_Fox

    Joined:
    Nov 14, 2018
    Posts:
    589
    If you're looking for a decent realtime GI for your procedural generated content, you do not have much options.
    Maybe you can get away with sky ambient, ambient occlusion and screen space GI. Otherwise you would need to develop your own kind of realtime GI, some sort of Voxel GI or custom probe system with textures 3D.

    Unfortunately, nobody will give you decent system for free, atleast not in Unity.

    It found this other project bringing voxel GI to the SRP, so maybe it can cover your needs or you can use it as a foundation to develop it further:
    https://github.com/Looooong/Unity-SRP-VXGI

    But maybe it is crucial to invest into another engine, which already give a realtime GI to start with. Let's face it, developing an own solution will be expensive. If you have a modular maze system, I could imagine it would work rather well with a low texel resolution. Usually, maze walls have rather thick walls, so in theory you should have not so much problem with light leaking. Looking at the screenshot of the SRP VXGI, I could work for your maze system.
     
    Last edited: May 25, 2022
    Amph1dian likes this.