The 2D layer · function
clipRectFor
The rectangle node may draw into, cut by every clipping ancestor between it and root.
Explained in Sprites and tilemaps.
function clipRectFor(root: UiNode, node: UiNode, out: UiRect): booleanimport { clipRectFor } from '@driftengine/ui2d';Parameters
| Parameter | Type | Description |
|---|---|---|
root | UiNode | |
node | UiNode | |
out | UiRect |
In depth
Returns false when nothing of it survives, which is the caller's signal to skip the subtree rather than issue a draw that covers no pixels.