max
The larger of two values.
max(a: Val, b: Val): Expr
Import math from shaders/std and use math.max.
Parameters
| Name | Type | Notes |
|---|---|---|
a | Val | |
b | Val |
Example
const safeRadius = max(params.uniforms.radius, 0.001)
See also
Used by
Aurora, Chrome, Crystal, FlowingGradient, Frost, Goo, Heatmap, Hologram, InkFlow, Irradiance, Marble, MeshGradient, Plastic, Prism, ReactionDiffusion, Sparkle, StudioBackground, TimeTrail, Voxels, Waveform