contactShadows.package
This package holds more than this page lists. See all of its files in its world.
README.md
ContactShadows
The scene small-scale grounding, as a component — the contact a shadow map cannot resolve, under a chair leg or a prop on a table.
entity(id).component.add("ContactShadows", { strength = 0.9, length = 0.35 })
Every world already draws contact shadows at this component's own defaults;
the component states a scene's own settings in their place. Every field is
live and persists with the scene. strength 0 turns them off while keeping the
settings authored; removing the last one in the scene hands the scene back to
the world's default.
| field | effect |
|---|---|
strength | How dark a fully occluded contact goes, in [0, 1]. 0 is off. |
length | Trace length in world units. |
steps | Samples along the trace. |
bias | Normal offset before the march starts. |
thickness | World-space thickness assumed for an occluder. |
localLights | Whether point, spot and distant lights supply contact of their own alongside the sun, at the high quality level; the medium and low levels trace the sun alone. |
maxTracedLights | How many lights a pixel may trace toward on top of the sun. |
Runtime control goes through
@builtin::systems.contactShadows.contactShadows.