Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

Higher Lightmap Resolution on Terrain

Discussion in 'Global Illumination' started by Zylex, May 21, 2020.

  1. Zylex

    Zylex

    Joined:
    Nov 25, 2008
    Posts:
    238
    In our game we have big terrains of around 1000x1000. However the lightmap size limit is 4096 causing blurry shadows on the terrain. Is Unity thinking of splitting up terrains somehow so we can have higher lightmap resolution for terrains?
     
    andrejpetelin likes this.
  2. fffMalzbier

    fffMalzbier

    Joined:
    Jun 14, 2011
    Posts:
    3,276
    So far that seem not to be an option.
    You could split the terrain yourself and to get 4 times the resolution (or more if you split it into more then 4 pieces)
    I found this post with a script for splitting the terrain ( not tested)
    https://forum.unity.com/threads/split-big-terrain-into-smaller-terrains.140645/#post-3219379

    I agree that an option for 8k lightmap texture would be nice.

    For terrains i often have seen that he baked shadows are only used for the distance shadow rendering and Realtime light for the near distance high quality. But that strongly depends on your usecase.
    https://docs.unity3d.com/Manual/LightMode-Mixed-Shadowmask.html
     
  3. rasmusn

    rasmusn

    Unity Technologies

    Joined:
    Nov 23, 2017
    Posts:
    99
    As fffMalzbier suggests, the only current option is to have several smaller terrain tiles instead of one huge tile.
     
  4. unity_JoEOh4GHvCb9Zw

    unity_JoEOh4GHvCb9Zw

    Joined:
    Sep 18, 2018
    Posts:
    1
    I've faced this issue too and ended up splitting the terrain into smaller pieces, however it introduced another issue. The terrain tiles have visible seams and the baked light behaves weird on the terrain.
    https://ibb.co/mh96Zb9
     

    Attached Files:

  5. uy3d

    uy3d

    Unity Technologies

    Joined:
    Aug 16, 2016
    Posts:
    187
    The artifacts that you see are most likely caused by the tree leaf meshes. You have to set the material on them to double sided GI.