Replies: 1 comment
-
Also want to know the solution of this which is really helpful |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
It's currently possible to automatically create a signed distance field (SDF) in 2D by using
LightOccluder2D
s and theirsdf_collider
property. The SDF can be used in custom shaders and for particle collisions.This works well, but it has the downside of all occluders being part of the same SDF. This can make it impossible to use with multiple shaders or particle collisions that should only apply to a some occluders.
As an example I have a project where I use the SDF to cast drop shadows (as seen in #43886) and for particle collision with solid objects. I now have some 'glass' objects that should not cast a shadow but which should 'stop' particles. As it is currently, this is not possible with the built in SDF.
I'm wondering if it would be possible to create separate SDFs based on, e.g., the occluders' light mask. I have no idea if this is technically feasible, but it would make SDFs more versatile.
Beta Was this translation helpful? Give feedback.
All reactions