Search Unity

Baked Lights Don't Work When Ambient Occlusion Is 0

Discussion in 'Global Illumination' started by Chris128, Dec 21, 2020.

  1. Chris128

    Chris128

    Joined:
    May 15, 2013
    Posts:
    12
    Unity 2020.2
    URP

    I was playing around with a shader graph and found that my materials were only visible if I had realtime lights in the scene. When I used baked lighting only, the textures were completely black no matter what I did.

    Eventually I realised that at some point I had set the ambient occlusion property on my shader graph to 0. Changing it back to 1 made everything work fine, but I'm just trying to understand why this is the case.

    Is it just that this parameter of the shader is expecting a texture map (like a normal map) rather than a numeric value, so setting it to 0 is basically telling it the entire map should be in full shadow?