position method

  1. @override
Point2D<double> position(
  1. double distance
)
override

Implementation

@override
Point2D<double> position(double distance) {
  Validate.inclusiveBetween(
      0, 1, distance, "Distance must be beteen 0 and 1 but was $distance");

  return Point2D<double>(
    CatmullRomSpline<T>(_p0.x, _p1.x, _p2.x, _p3.x).position(distance),
    CatmullRomSpline<T>(_p0.y, _p1.y, _p2.y, _p3.y).position(distance),
  );
}