shadowOffset

The coordinate a shadow reads the child's silhouette from: distance away in the compass direction angle.

shadowOffset(opts: {angle: ArgSpec; distance: ArgSpec}): (params: RttFilterParams) => Expr

Import effects from shaders/std and use effects.blurs.shadowOffset.

angle is in degrees, 0 up, 90 right, 180 down. distance (0–1) is a fraction of the canvas height and covers the same number of pixels in either axis. Pass the result as the at of silhouetteCoverage.

Parameters

NameTypeNotes
opts{angle: ArgSpec; distance: ArgSpec}

Example

silhouetteCoverage({at: shadowOffset({angle: p('angle'), distance: p('distance')}), blur: p('blur')})

See also

Used by

DropShadow