Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

progressive light mapping: less files to decrease build size?

Discussion in 'Global Illumination' started by strongbox3d, Dec 16, 2018.

  1. strongbox3d

    strongbox3d

    Joined:
    May 8, 2012
    Posts:
    860
    Hello guys,

    I have this game in iOS and Android, and noticed that the amount of files from the light map increase the build size by a lot of mbs. Is it there any tips in reducing the amount of files when light mapping with progressive light mapping? See attachment

    One_of_the_gameLevels.jpg

    Regards,
    Carlos
     
    futurlab_xbox likes this.
  2. kristijonas_unity

    kristijonas_unity

    Unity Technologies

    Joined:
    Feb 8, 2018
    Posts:
    1,080
    Hey! First of, you need to decide whether or not you actually need to use shadowmask textures. If most assets in your game are static, you could get away with using either Baked Indirect or Subtractive lighting modes.

    Another way to reduce the number of lightmaps, is to increase the lightmap size in the Lighting Settings. You will end up with fewer lightmap textures, albeit they will be larger in size individually.

    Finally, you could use Baked Lightmap scene view and optimize lightmap size per object basis. The value you need to tweak is Scale In Lightmap, and it is located in the Mesh Renderer component.
     
  3. strongbox3d

    strongbox3d

    Joined:
    May 8, 2012
    Posts:
    860
    kristijonas_unity, thank you so much for your input! Last night I tried both Baked Indirect and Subtractive and both gave me an awful look. I haven't try increasing the lightmap size in the Lighting Settings or the lightmap size per object yet, I will do that now to see if that helps me and the look is acceptable. I hope either of these solutions help me because the build size is too big the way I have it right now, so I can't create new assets or environment for updates and I need to do so, since the game is out already and I want to keep updating with more stuff on it.

    I really appreciate your input! Thank you.

    Regards,
    Carlos
     
    kristijonas_unity likes this.