Calculates the interpolation of a vector.
// Returns (2.33, 2.33, 2.33) (interpolated vector with weights 2, 3, 1)const v = Chalkboard.vect.interpolate(Chalkboard.vect.init(1, 2, 4), 2, 3, 1); Copy
// Returns (2.33, 2.33, 2.33) (interpolated vector with weights 2, 3, 1)const v = Chalkboard.vect.interpolate(Chalkboard.vect.init(1, 2, 4), 2, 3, 1);
The vector
The x-value (for 2D, 3D, and 4D vectors)
The y-value (for 2D, 3D, and 4D vectors)
Optional
The z-value (for 3D and 4D vectors)
The w-value (for 4D vectors)
Calculates the interpolation of a vector.
Example