lerp method

V3 lerp(
  1. V3 o,
  2. double amount
)

Linear interpolation between this and o by amount.

amount should be in the range [0.0, 1.0].

Implementation

V3 lerp(V3 o, double amount) => _v3(
  x + amount*(o.x - x),
  y + amount*(o.y - y),
  z + amount*(o.z - z),
);