Expand description
Mathematical structs and functions.
Structs§
- Cubic
Bezier2d - A cubic bezier curve
- CubicFn
- A cubic function, which is a polynomial of the form ax^3 + bx^2 + cx + d.
- Line
Segment2d - A line segment
- Lookup
Table - A lookup table
- Quadratic
Bezier2d - A quadratic bezier curve
Traits§
- Parametric
Curve2d - A parametric curve in 2D space.
Functions§
- equidistant_
points_ along_ curve - Finds a set of evenly spaced points along the given parametric curve.
- intersect_
curves - Finds intersection between two curves, if one exists.
- normalize_
with_ derivative - Normalises a vector and computes the derivative of the normalised vector.
- project_
local - Projects a point onto a local coordinate system.
- project_
point_ onto_ curve - Projects a point onto a parametric curve.
- rot90
- Rotates a vector 90 degrees clockwise.
- subdivided_
points_ along_ curve - Approximates a curve by subdividing it until all segments are no longer than
max_lengthunits in length. - subdivided_
samples_ along_ curve - Approximates a curve by subdividing it until all segments are no longer than
max_lengthunits in length.