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

Vulkan Mobile backend: Angular Distance (PCSS) does not work with DirectionalLight3D shadows #55882

Open
Tracked by #55871
Calinou opened this issue Dec 12, 2021 · 1 comment

Comments

@Calinou
Copy link
Member

Calinou commented Dec 12, 2021

Godot version

4.0.dev (2a9dd65)

System information

Fedora 34, GeForce GTX 1080 (NVIDIA 470.74)

Issue description

Angular Distance (PCSS) does not work as expected with directional light shadows. It is not completely ignored, as the shadowmap is still adjusted accordingly.

Vulkan Clustered backend (working)

simplescreenrecorder-2021-12-12_22.44.15.mp4

Vulkan Mobile backend (broken)

simplescreenrecorder-2021-12-12_22.42.43.mp4

On point lights, adjusting Size while using the Vulkan Mobile backend works as expected:

simplescreenrecorder-2021-12-12_22.46.16.mp4

Steps to reproduce

  • Add several MeshInstance3D nodes so you can see shadows being casted.
  • Add a DirectionalLight3D node. Enable shadows on it.
  • Add an OmniLight3D and SpotLight3D node. Enable shadows on them.
  • Select the DirectionalLight3D and increase Angular Distance slowly. Notice how shadows become blurrier the further away they are from the caster.
  • Select the OmniLight3D and SpotLight3D, and increase Size (not Range) slowly. Notice how shadows become blurrier the further away they are from the caster.
  • Switch to Vulkan Mobile backend in the project settings (search for back end).
    • Note: The MRP linked below already uses the Vulkan Mobile backend by default.
  • Notice that changing Angular Distance on DirectionalLight3D no longer makes the shadows progressively blurrier the further away they get from the object casting them. Shadows will however become more pixelated as the angular distance increases.
    • However, point light shadows remain correct.

Minimal reproduction project

test_vulkan_clustered_vs_mobile_lights.zip

@clayjohn
Copy link
Member

I think the plan is to remove PCSS entirely from the mobile renderer as it will perform horribly on tile-based architectures.

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

2 participants