Skip to content

Function: over() ​

ts
function over(color, under, opacity?): RGBA;

Experimental

color (straight alpha) times opacity over under (opaque): the color the flat trace shows. Prisms are drawn opaque, so they keep writing depth (translucent ones would need sorting that nested and adjacent prisms defeat); what is under a shape in the flat trace is the paper or, for a nested tile, its parent.

Parameters ​

ParameterTypeDefault value
colorRGBAundefined
underRGBAundefined
opacitynumber1

Returns ​

RGBA

Released under the MIT License.