getPoint method

  1. @override
dynamic getPoint(
  1. num t,
  2. dynamic optionalTarget
)
override

Implementation

@override
getPoint(t, optionalTarget) {
  var point = optionalTarget ?? Vector2(null, null);

  if (t == 1) {
    point.copy(v2);
  } else {
    point.copy(v2).sub(v1);
    point.multiplyScalar(t).add(v1);
  }

  return point;
}