playcanvas / playcanvas/engine

Spotlight shadows bleed when using clustered lighting

Open
#8,058 1 comment 2 reactions 1 assignee View on GitHub

@mvaligursky is already working on this.

Since Oct 20, 2025.

area: graphics
Dominant language
JavaScript
Stars
16.8k
Forks
2k
Avg merge
4h 32m
Merged PRs (30d)
222

Description

When using clustered lighting, spotlight shadows bleed light around the cone edges. It's especially noticeable when using similar inner and outer cone angles. In the example below, both cone angles are set to 20. I have to lower the inner cone angle to around 15 for the bleed to disappear (different values needed on different devices).

Clustered lighting disabled Clustered lighting enabled
Image Image

The amount of bleed increases as the outer cone angle is lowered, as visible in this video.

https://github.com/user-attachments/assets/87676d17-3e1e-4105-9e43-a46d99eaac8f

We noticed this while working with spotlights that we wanted to project orthographic-ish light cookies. This issue hinders us from doing so, since we can't seem to find a cone angle that doesn't bleed on any device.

Test project: https://playcanvas.com/project/1408857/overview/spotlight-shadow-bleed

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.