Search Unity

  1. We are looking for feedback on our SRP Rendering APIs through this Survey.
    Dismiss Notice
  2. Unity 2020.2 has been released.
    Dismiss Notice
  3. Good news ✨ We have more Unite Now videos available for you to watch on-demand! Come check them out and ask our experts any questions!
    Dismiss Notice

Help Wanted Realtime lights leak through walls

Discussion in 'Global Illumination' started by ScetticoBlu, Nov 26, 2020.

  1. ScetticoBlu

    ScetticoBlu

    Joined:
    Nov 26, 2020
    Posts:
    5
    Hi all,
    I have an indoor scene where the main lights come from the corridor. These lights are set to mixed.
    Here a picture of my problem. Inside all the rooms I have this effect where the lights from the outside bounces over that white wall. I swear I read everything I found online, changing bias, adding new meshes in order to block the light but this cause a shadow undesired on the other side of the wall. I have no idea why this is happening.
    upload_2020-11-26_16-12-18.png
    Here the section of my wall. Yellow is where the light bounces inside the room.
    upload_2020-11-26_16-20-38.png
    The three meshees composing the wall aren't even clipping, all seems clear, how can I stop the light properly? It's really annoying because it would a huge inpact on the gameplay. I'm not using HDRP.
    If someone know the problem, he could save me hours of useless attempts trying fixing it. Thanks!
     
  2. KEngelstoft

    KEngelstoft

    Unity Technologies

    Joined:
    Aug 13, 2013
    Posts:
    1,263
    If you are using mixed lights and the unwanted shading is within the real time shadow range there are several tings you could try:
    Make sure all blocking geometry is set to cast shadow.
    Make sure shadow map resolution is sufficient and check the biasing setting.
    Make sure the offending light is actually set to shadow casting.
    Make sure the geometry which is showing the unwanted lighting is set to receive shadows.

    Use the frame debugger to inspect the offending draw call to verify the material/shader have the right keywords and inputs set.
     
    polemical likes this.
  3. ScetticoBlu

    ScetticoBlu

    Joined:
    Nov 26, 2020
    Posts:
    5
    Thanks for your answers! I didn't try your solutions because I found that merging in blender all the green walls of the room doesn't let the light leaks through. Probably Realtime light doesn't like multiple meshes one next to another.
     
    Pema-Malling likes this.
unityunity