Shadow
gfx.shadow.set_positional_atlas_quadrant_subdiv
ClientSets the subdivision level of a positional shadow atlas quadrant
Syntax
local status = gfx.shadow.set_positional_atlas_quadrant_subdiv(
quadrant,
subdiv
)Lights are placed in a quadrant that matches how large they appear on screen.
- Close lights — land in quadrants with few subdivisions, which have the sharpest shadow maps.
- Distant lights — land in quadrants with many subdivisions, where a small shadow map is enough.
- Capacity — a quadrant holds only as many shadow maps as its subdivision allows, extra lights may lose shadows.
- Default — quadrants
0and1useX4, quadrant2usesX16and quadrant3usesX64.
Parameters
| Type | Name | Description |
|---|---|---|
int | quadrant | Quadrant index to target Must be between 0 and 3, an error is raised otherwise |
gfx.shadow.subdiv | subdiv | Subdivision level to apply |
Returns
| Type | Name | Description |
|---|---|---|
bool | status | true on successful execution, false otherwise |
Examples
gfx.shadow.set_positional_atlas_quadrant_subdiv(0, gfx.shadow.subdiv.X1)gfx.shadow.set_positional_atlas_quadrant_subdiv(3, gfx.shadow.subdiv.DISABLED)gfx.shadow.set_positional_atlas_quadrant_subdiv(0, gfx.shadow.subdiv.X16)
gfx.shadow.set_positional_atlas_quadrant_subdiv(1, gfx.shadow.subdiv.X64)
gfx.shadow.set_positional_atlas_quadrant_subdiv(2, gfx.shadow.subdiv.X256)
gfx.shadow.set_positional_atlas_quadrant_subdiv(3, gfx.shadow.subdiv.X1024)