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. Let us know your feedback about the Global Illumination changes in the 2023.2 beta.
    Dismiss Notice
  3. Dismiss Notice

Question Realtime shadows in Baked light scene

Discussion in 'Global Illumination' started by Alde-Baran, Jun 24, 2023.

  1. Alde-Baran

    Alde-Baran

    Joined:
    Nov 15, 2019
    Posts:
    35
    I don't know how to explain this.
    Simply the realtime shadow of the box only created by some lights on the scene.
    I selected this part of the scene, there is only top right light create realtime shadows for the cube.
    upload_2023-6-24_14-45-50.png

    upload_2023-6-24_14-50-5.png
    This is the light map settings.
    This is happening in other sides of the scenes and also in my any other scene too.
    How can i fix this? I want all lights to create realtime shadows.

    I'm currently using Unity 2019.4.16f1 LTS version. No URP or etc.
     
  2. DevDunk

    DevDunk

    Joined:
    Feb 13, 2020
    Posts:
    4,362
    Are the lights set to mixed mode?
     
  3. Alde-Baran

    Alde-Baran

    Joined:
    Nov 15, 2019
    Posts:
    35
    Yep, all of them are mixed
     
  4. DevDunk

    DevDunk

    Joined:
    Feb 13, 2020
    Posts:
    4,362
    Are you maybe at the per object limit
     
  5. Alde-Baran

    Alde-Baran

    Joined:
    Nov 15, 2019
    Posts:
    35
    What is per object limit?
     
  6. DevDunk

    DevDunk

    Joined:
    Feb 13, 2020
    Posts:
    4,362
    In forward rendering 1 object can only have a certain amount of active lights acting on it. Usually 8 I think
     
  7. Alde-Baran

    Alde-Baran

    Joined:
    Nov 15, 2019
    Posts:
    35
    Where do i increase it?
     
  8. DevDunk

    DevDunk

    Joined:
    Feb 13, 2020
    Posts:
    4,362
    Woth URP you have to use forward+ or deferred, not sure for built in
     
  9. Alde-Baran

    Alde-Baran

    Joined:
    Nov 15, 2019
    Posts:
    35
    I search a bit and couldn't find per object limit on Built in renderer. I create a test project in URP, it don't even support shadows on point lights. I didn't try HDRP because even it does, my PC can't run HDRP properly so there is no point of trying.

    I don't have any idea how to solve it. I guess i'll ignore it, and hope nobody care
     
  10. DevDunk

    DevDunk

    Joined:
    Feb 13, 2020
    Posts:
    4,362
    2021.3 support point light shadows.
    Being on a multiple year old version is the issue for that
     
    Alde-Baran likes this.
  11. AcidArrow

    AcidArrow

    Joined:
    May 20, 2010
    Posts:
    10,977
    For URP, built-in supported them for many many years.

    @Alde-Baran did you check the pixel light count in the quality settings?
    upload_2023-7-6_6-43-8.png
     
    Alde-Baran likes this.
  12. Alde-Baran

    Alde-Baran

    Joined:
    Nov 15, 2019
    Posts:
    35
    Sorry, i usually don't look at Unity forum, i saw this now.

    I checked btw. It set to 10, idk what it effects
    upload_2023-7-17_0-53-48.png
     
  13. Neto_Kokku

    Neto_Kokku

    Joined:
    Feb 15, 2018
    Posts:
    1,750
    Maybe the editor is previewing a lower quality level that has a smaller value? I'm not experienced in mixed mode lights, but you could also try switching from forward rendering to deferred rendering since that deals better with larger number of lights (forward causes all objects to be rendered one extra time with additive blending for each light that hits them).
     
  14. Alde-Baran

    Alde-Baran

    Joined:
    Nov 15, 2019
    Posts:
    35
    I try to adding a Camera and set Rendering to deferred, but it still the same
     
  15. Alde-Baran

    Alde-Baran

    Joined:
    Nov 15, 2019
    Posts:
    35
    Also i just discovered, the only light cast real-time shadow, was never baked.
    It set to mixed, i have no idea why.
    upload_2023-7-17_21-46-50.png