tan

The tangent of an angle in radians.

tan(x: Val): Expr

Import math from shaders/std and use math.tan.

Parameters

NameTypeNotes
xVal

Example

const slope = tan(mul(params.uniforms.tilt, 0.017453292519943295))

See also

  • sin — The sine of an angle in radians, −1..1.
  • cos — The cosine of an angle in radians, −1..1.
  • atan2 — The angle of the point (x, y) in radians, −π..π.