Search Unity

Problem with lightmap

Discussion in 'Global Illumination' started by hasseyg, Dec 16, 2020.

  1. hasseyg

    hasseyg

    Joined:
    Nov 16, 2013
    Posts:
    81
    Hi, I have a problem with my lightmap. I have a tunnel mesh that is underneath a terrain and it is next to a separate road mesh. I have put a hole in the terrain at the entrance of the tunnel. When I bake the light map there is no smooth lighting from the tunnel mesh to the road mesh. There is just a sharp contrast where the 2 meshes meet. I am using URP on Unity 2020.2. Does anyone know what is going on here? thanks

     

    Attached Files:

    Last edited: Dec 16, 2020
  2. uy3d

    uy3d

    Unity Technologies

    Joined:
    Aug 16, 2016
    Posts:
    187
  3. hasseyg

    hasseyg

    Joined:
    Nov 16, 2013
    Posts:
    81
    Hi, the surfaces do not turn red when viewing the texel validity.
    The tunnel mesh only consists of the inner walls and is not a solid mesh, so I tried closing off the mesh, so the back faces were not visible, but that did not work either.
     
  4. hasseyg

    hasseyg

    Joined:
    Nov 16, 2013
    Posts:
    81
    I removed the terrain and used the closed tunnel mesh so the light would not pass through and the light baked correctly, so it is definitely the terrain causing the issue.
     
  5. hasseyg

    hasseyg

    Joined:
    Nov 16, 2013
    Posts:
    81
    Ok, for anyone else having the same problem, after further testing with a simple mesh, I can confirm the lightmapping does not work with terrain holes, so I will submit a bug report.

    thanks
     
    Pema-Malling likes this.
  6. hasseyg

    hasseyg

    Joined:
    Nov 16, 2013
    Posts:
    81
    After submitting my bug report, the case was closed stating that it was fixed. Guess what... the problem was not fixed. Therefore putting my project on hold and submitting a bug report was a complete waste of time.
     
  7. Pema-Malling

    Pema-Malling

    Unity Technologies

    Joined:
    Jul 3, 2020
    Posts:
    320
    Hey there, I'm sorry to hear your issue still isn't resolved. Could you provide me with case ID for the bug report?
     
  8. Zylex

    Zylex

    Joined:
    Nov 25, 2008
    Posts:
    238
    Having the same issue here:

    With terrain on:


    With terrain off:



    Is there any way or setting to fix this yet? We use 2020.2.5f1 with Built-in pipeline