pointAt method

Point pointAt(
  1. double t
)

Get point on curve at parameter t (0 = start, 1 = end)

Implementation

Point pointAt(double t) {
  final mt = 1 - t;
  return Point(
    mt * mt * start.x + 2 * mt * t * control.x + t * t * end.x,
    mt * mt * start.y + 2 * mt * t * control.y + t * t * end.y,
  );
}