pointAt method

Offset pointAt({
  1. required double angle,
  2. required double distance,
})

The point on a ray at angle (radians, 0 = +x, clockwise as y grows down) at the given distance from center.

Implementation

Offset pointAt({required double angle, required double distance}) => Offset(
  center.dx + math.cos(angle) * distance,
  center.dy + math.sin(angle) * distance,
);