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

LWRP Lighting Issue

Discussion in 'Universal Render Pipeline' started by hassanshahid, Aug 7, 2019.

  1. hassanshahid

    hassanshahid

    Joined:
    May 7, 2019
    Posts:
    1


    Lights behaving strangely in LWRP. Shadows and shading is weird too. Using the LWRP-High preset. Unity 2019.2

    Tried a new project but same issues. I'm using two real-time spotlights, no directional or ambient light. LWRP should be able to handle that if I'm not mistaken.
     
    cmart and Cynicat like this.
  2. BenThomas5

    BenThomas5

    Joined:
    Jul 23, 2019
    Posts:
    10
    A little update on this issue. In order to support this feature efficiently in all platforms it will require some changes added to Unity. i.e, it's not something I can fix in the package. So it will take a few weeks until this is fixed but I just wanted to let you know it's being worked on.
     
  3. JohnKP-Mindshow

    JohnKP-Mindshow

    Joined:
    Oct 25, 2017
    Posts:
    56
    Having the same issue as well.

    2019.2 and the associated LWRP from package manager.

    Any updates on this? Put me dead in the water.
     
  4. Dimn721

    Dimn721

    Joined:
    Mar 30, 2017
    Posts:
    9
  5. tooRelic

    tooRelic

    Joined:
    Dec 1, 2017
    Posts:
    3
    Are the light's Render Mode set to Auto / Important / Not Important? Not recommending it's the solution, but has it any affect?
     
  6. larsbertram1

    larsbertram1

    Joined:
    Oct 7, 2008
    Posts:
    6,898
  7. JohnKP-Mindshow

    JohnKP-Mindshow

    Joined:
    Oct 25, 2017
    Posts:
    56
    Had no effect for me.
     
  8. fherbst

    fherbst

    Joined:
    Jun 24, 2012
    Posts:
    802
    Same here. Really hoping for a fix. Realtime lighting is basically unusuable right now with 2 lights.
     
  9. MetalDonut

    MetalDonut

    Joined:
    Feb 7, 2016
    Posts:
    127
    I've had this issue too and also posted on it (didn't get any replies). Looks like this was originally flagged 18 months ago from that other thread posted above! I was working in 2019.2 so tried upgrading to 2019.3b to see if it has been resolved but the issue still hasn't been fixed.

    Being that LWRP/URP is meant to be somewhat stable this is a huge disappointment and I agree it's unusable. Has anyone heard of this being fixed anytime soon??
     
  10. fherbst

    fherbst

    Joined:
    Jun 24, 2012
    Posts:
    802
    I reported a bug: Case 1190415 [URP] Light glitches
    @LeonhardP would be great if you can take a look at this thread, thanks!
     
    LeonhardP likes this.
  11. pavelpry

    pavelpry

    Joined:
    Mar 4, 2015
    Posts:
    2
    Same problem here. I've reported it two months ago. It happens only with VR enabled. What I've found is unity_LightIndices array receives (0,0,0,0) and so every light is rendered with parameters of the first light only.

    This is really bad as we can't upgrade to a newer versions of Unity until this is fixed.
     
  12. JohnKP-Mindshow

    JohnKP-Mindshow

    Joined:
    Oct 25, 2017
    Posts:
    56
    Yeah it seems like the various rendering pipelines are all in their own state of disarry in this transition Unity is in. But its really unclear what the most stable rendering solution is. So I've just lived with the lighting issue until things....settle down a bit?

    But it's unclear when that would be as it seems communication with the community is very hit and miss lately
     
  13. Danielsantalla

    Danielsantalla

    Joined:
    Jan 7, 2015
    Posts:
    75
    Any new info on this issue? I'm having the same problem :(
     
  14. fherbst

    fherbst

    Joined:
    Jun 24, 2012
    Posts:
    802
    I got feedback that it will be fixed on 2019.3.0b11 and is already fixed on 2020.1.0a8 (it was seemingly caused by a Core Engine bug in culling code).
     
    MetalDonut likes this.
  15. liiir1985

    liiir1985

    Joined:
    Jul 30, 2014
    Posts:
    147
    I looked into the release note, it says it's introduced in 2019.3.a12, not seen in previous released version, but it's absolutely not the case, I'm having exactly the same issue in 2019.2 with lwrp, can you please share your repro project or share the step to setup a such repro project? Because I can't reproduce it with minimal setup, it only appears in the project which is too big to submit
     
  16. taylorjames9

    taylorjames9

    Joined:
    Nov 21, 2012
    Posts:
    4
    Same issue here. Using Unity 2019.3.4f1 Putting together a demo on lighting in this game and this issue makes it... not do-able.
     
  17. phil_lira

    phil_lira

    Unity Technologies

    Joined:
    Dec 17, 2014
    Posts:
    584
    @taylorjames9 does the issue reproduce if you disable SRP batcher in the pipeline asset?
    could you submit a bug report?
     
  18. ChanzDog

    ChanzDog

    Joined:
    Sep 28, 2017
    Posts:
    43
  19. fherbst

    fherbst

    Joined:
    Jun 24, 2012
    Posts:
    802
    Yes, I think that is very much related and in line with what I've been seeing.

    Related bug reports from my end:

    I think the most relevant of my bug reports is
    Case 1190415 (Closed) [URP] Light glitches related to SRP Batcher
    https://issuetracker.unity3d.com/is...ops-emitting-light-at-certain-points-of-scene
    https://issuetracker.unity3d.com/is...e-their-unitylightindices-0-set-to-all-zeroes
    The second issue is ONLY fixed in 2020, and has me asking for a backport to 2019.3 on it, with no response so far. @phil_lira can this be backported?

    Case 1225499
    ([URP] Incorrect Light / Shadow Culling with Shadow Distance and camera near clip plane)
    no response so far

    Case 1201994 (Closed) [URP] Lights/Shadows are incorrectly culled
    closed since 2019.3.0f3 and partially fixed that specific issue

    Case 1201992 (Closed) [URP] Existance of spotlight already changes scene properties without the spotlight actually contributing to scene lighting

    As some of those are closed and the issue is not fully fixed I think it would be great if you can submit a new case.
     
    Last edited: Apr 2, 2020
  20. phil_lira

    phil_lira

    Unity Technologies

    Joined:
    Dec 17, 2014
    Posts:
    584
    Hey Felix thank you!

    QA pointed me out these cases have this as original case https://issuetracker.unity3d.com/is...ops-emitting-light-at-certain-points-of-scene

    This is backported to 2019.3, but just in case we will re-test your specific issue with 2019.3, maybe we had a false duplicate here.



    We will look at it soon.


    These were closed as duplicates, I've asked them to be reverified.
     
    ChanzDog and fherbst like this.
  21. ChanzDog

    ChanzDog

    Joined:
    Sep 28, 2017
    Posts:
    43
    Thanks, guys. I have submitted a bug report along with a very simple project using no custom features. Should be very simple to see on your end what the issue is.
     
  22. fherbst

    fherbst

    Joined:
    Jun 24, 2012
    Posts:
    802
  23. Navid38

    Navid38

    Joined:
    Dec 21, 2018
    Posts:
    5
    just change the color space from linear to Gamma, linear does not work on some mobile devices.
     
    Last edited: May 5, 2020
  24. nasos_333

    nasos_333

    Joined:
    Feb 13, 2013
    Posts:
    13,286
    Hi,

    Could all the above be related to an issue i have, i try to grab the spot lights in shader using GetAdditionalLightsCount(); and seems i can only get one light in random. I have defined 7 lights per object in URP pipeline settings.

    Thanks