Search Unity

Inconsistent Environment Light baking between CPU/GPU

Discussion in 'Global Illumination' started by AcidArrow, Feb 23, 2020.

  1. AcidArrow

    AcidArrow

    Joined:
    May 20, 2010
    Posts:
    11,799
    Since CPU Lightmapper no longer works consistently in 2019.3...

    (I can start one bake, but if I don't let it finish, I have trouble making it start another, it gets to the point where it says "Baking..." then it just stays there without showing me anything 50% of the time)

    ...can we please get a backport of whatever fix you did in 2020.1 alpha to make "Environment Light" baking be consistent between the CPU and GPU lightmapper, so I can be finally able to use the GPU Lightmapper as my main lightmapper?

    In 2019.3, GPU produces visibly darker results from Environment Light (I thought it was that I was using an HDR map at first, but it's the same for simple colors). That's in Gamma space, I didn't check if it's an issue with Linear.

    darkerGPU.jpg

    If the fix for this only remains available in 2020.x, it pretty much means I have to wait a little less than 2 whole years to be able to use the GPU Lightmapper, since I'm going from LTS to LTS.

    You could also say I could adjust all my lighting settings to get the balance I want again, but I refuse to do that when it's a bug and a thing I will have to revert if we ever move to 2020.x, since it doesn't happen there.

    For what it's worth: 2018.4 also does NOT have this issue. This is a thing that was introduced sometime in 2019.x and then was fixed in 2020.

    This does not seem like a missing feature to me, it looks like a straight up bug, as such I think it should be fixed in 2019.3-4
     
    Last edited: Feb 24, 2020
    Raul_T likes this.
  2. unit_dev123

    unit_dev123

    Joined:
    Feb 10, 2020
    Posts:
    989
    Sir i try with 2019.3x, no sun, light only environment light, no post effects, can not see this issue.
     
  3. AcidArrow

    AcidArrow

    Joined:
    May 20, 2010
    Posts:
    11,799
    Gamma or Linear? It's probably a Gamma only issue.
     
  4. unit_dev123

    unit_dev123

    Joined:
    Feb 10, 2020
    Posts:
    989
    maybe can you confirm?
     
  5. AcidArrow

    AcidArrow

    Joined:
    May 20, 2010
    Posts:
    11,799
    Confirm what? What are you talking about?

    I'm starting to feel like you're a bot, your answers are almost always adjacent to a reply that makes sense.
     
  6. unit_dev123

    unit_dev123

    Joined:
    Feb 10, 2020
    Posts:
    989
    to confirm if issues arise with only gamma or linear space or both, is important to be as thorough as possible so unity devs can trouble shoot issue if issue exist
     
    Last edited: Feb 24, 2020
  7. kristijonas_unity

    kristijonas_unity

    Unity Technologies

    Joined:
    Feb 8, 2018
    Posts:
    1,080
    @AcidArrow, could you please submit a bug report along with your repro scene? We took a glance at the features that landed between 2019.3.X and 2020.1.X cycle, and could not determine what could have caused this regression.

    Also, keep in mind that if this fix happened to land as a part of a larger feature, we will not be able to backport it.
     
  8. kristijonas_unity

    kristijonas_unity

    Unity Technologies

    Joined:
    Feb 8, 2018
    Posts:
    1,080
    This seems like a more serious issue. Could you please report it, once you'd get the chance?
     
  9. AcidArrow

    AcidArrow

    Joined:
    May 20, 2010
    Posts:
    11,799
    I care more about the other issue though.

    But for that specific issue, I have a sneaking suspicion it has something to do with my project, so if I'm unable to re-create it on a new project (as I'm suspecting), narrowing it down might be a multi-day kind of deal and I don't have time to do that.

    In any case, I don't have time or energy to do bug reports (especially since one of them has a high chance of not getting fixed, and the other I don't really care about) so we might as well forget the whole thing.
     
  10. unit_dev123

    unit_dev123

    Joined:
    Feb 10, 2020
    Posts:
    989
    any resolution, I tried linear and gamma, and all fine.
     
  11. AcidArrow

    AcidArrow

    Joined:
    May 20, 2010
    Posts:
    11,799
    So, the original brightness issue, that I did report ( here : https://issuetracker.unity3d.com/is...rker-compared-to-the-progressive-cpu-lightmap ) is probably a duplicate of this issue:

    https://issuetracker.unity3d.com/issues/gpu-baking-does-not-match-cpu

    Can you tell me if that fix has landed in a 2019.3.9f1? Because if it did, then it's not a duplicate, since I can still replicate the issue.
     
  12. AcidArrow

    AcidArrow

    Joined:
    May 20, 2010
    Posts:
    11,799
    I'm also still experiencing having difficulty to start CPU baking after successfully GPU baking, but I'm really not willing to produce a minimal repro for it. (since I think it will take me of upwards a full day to narrow it down)

    (actually, maybe it does work, but it doesn't update while it's working, and it's much slower than it should. Also cancelling the CPU bake, still leaves a process in taking much of the processor that doesn't go away for many many minutes).
     
    Last edited: Apr 16, 2020
  13. uy3d

    uy3d

    Unity Technologies

    Joined:
    Aug 16, 2016
    Posts:
    187
    The fix is first included in the relnotes for 2019.3.10f1. It's this one here:

    GI: Fixed an issue with normals during bounce calculations in the GPU lightmapper, leading to large differences in brightness between the CPU and the incorrect GPU lightmapper. (1206157)
     
    AcidArrow and valarnur like this.
  14. kristijonas_unity

    kristijonas_unity

    Unity Technologies

    Joined:
    Feb 8, 2018
    Posts:
    1,080
    Can confirm that it landed in 2019.3.10f1.
     
    AcidArrow likes this.
  15. AcidArrow

    AcidArrow

    Joined:
    May 20, 2010
    Posts:
    11,799
    Thank you. Looking forward to 2019.3.10f1
     
    KEngelstoft likes this.
  16. AcidArrow

    AcidArrow

    Joined:
    May 20, 2010
    Posts:
    11,799
    So I tried 2019.3.10f1 (didn't realize it was already out), and I can confirm, issue is fixed.

    While the original issue may seem petty/minor to people reading this thread, this fix was the last blocker that stopped me from being able to use the GPU lightmapper in our game. And since we're going from LTS to LTS, this fix means I'll be able to use GPU lightmapper a full year earlier than if this wasn't fixed in 2019.3.