Search Unity

Do Direct Samples and Lightmap Parameters effect performance when using mixed lighitng?

Discussion in 'Global Illumination' started by mrCharli3, Jun 22, 2019.

  1. mrCharli3

    mrCharli3

    Joined:
    Mar 22, 2017
    Posts:
    392
    I don't know a lot about lighting, but as far as I understand, when using mixed lighting, static objects end up en the lightmap, and the rest (dynamic) are dealt with by realtime lighting.

    When I bake a lightmap, does it actually effect the users performance if I use more samples, higher lightmap resolution or better lighmap parameters, or does it only effect the time it take to do the actual bake?
     
    Last edited: Jun 22, 2019
  2. kristijonas_unity

    kristijonas_unity

    Unity Technologies

    Joined:
    Feb 8, 2018
    Posts:
    334
    Progressive Lightmapper does early out eventually, but not immediately, which will result in longer bake times, even when using just mixed lights.
     
  3. mrCharli3

    mrCharli3

    Joined:
    Mar 22, 2017
    Posts:
    392
    Hi, thanks, I already knew that you get longer bake times, my questions was regarding how user performance is effected :) Maybe you answered that but then I didnt understand.

    "When I bake a lightmap, does it actually effect the users performance if I use more samples, higher lightmap resolution and/or better lighmap parameters (i.e will performance for the players be worse), or does it only effect the time it takes me to do the actual bake?"
     
  4. uy3d

    uy3d

    Unity Technologies

    Joined:
    Aug 16, 2016
    Posts:
    84
    Increasing the sample count only affects baking times, so is an editor only thing.
    Higher lightmap resolutions result in larger textures that must be kept in memory, so this can affect the end user. Cache efficiency can also go down with that.
    As for the other parameters, it depends. Compression for example affects end users as well, as the lightmaps will be smaller in memory, so loading times go down and the texture cache can work more efficiently. Other parameters may only affect the baking process.
     
  5. mrCharli3

    mrCharli3

    Joined:
    Mar 22, 2017
    Posts:
    392
    Great, thanks for clarifying :)