Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Directional lights that are not active on any layer change the color of subsurface scattering #1150

Open
2 tasks done
Revmatek opened this issue May 10, 2024 · 2 comments
Open
2 tasks done

Comments

@Revmatek
Copy link

Is there an existing issue for this?

  • I have searched the existing issues.

Have you checked the documentation to resolve your problem?

  • I have read the linked documentation and could not resolve my issue.

Current Behavior

If you create a second directional light and turn everything off (culling mask, shadows) and adjust the intensity it will affect the underwater lighting. You can also observe this by changing the existing light culling.

You will see the surface lighting is different then the underwater lighting.

Expected Behavior

The underwater lighting should only be affected by the main directional light when enabled / not culled

Steps To Reproduce

  1. Open main.unity
  2. Create a second directional light
  3. Change the settings so that the light isn't really on
    image
  4. Go underwater
  5. Observer red screen
    image
    image

Or

  1. Change the culling mask of the main light to Nothing
  2. Set the intensity to 1000
  3. Go underwater
  4. Observe white screen

Unity Version

2021.3.26f1

Crest Version

4.19

Render Pipeline

Built-In

Editor or Standalone

Editor (Edit Mode), Editor (Play Mode), Standalone

Environment

No response

Anything else?

This is not very important. More of an FYI. You can work around this by changing the intensity of the light to 0 if you want it off. It does not seem intentional and it is weird that a second directional light can also cause it. I noticed this happened with intensity 1, for the steps it is much higher to make it apparent for reproducing the problem.

@daleeidd
Copy link
Collaborator

daleeidd commented May 10, 2024

We use RenderSettings.sun without any further checking. Not sure if this will change but will mark as enhancement. I should document this somewhere at the very least.

@FirstMnM
Copy link

Hopefully this would not change some of the current behavior in this area. HDRP - I have a disabled (not checked) Directional light on a different light layer that I'm feeding in as the Primary Light on Crest Ocean. It nicely colors water without illuminating the scene any extra, and provides a bit of a different look than the underwater fog.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants