Round the values of a vector.
The target vector.
Error - When a computed component is NaN or non-finite.
round({ x: 0.4, y: 1.5 }); // -> { x: 0, y: 2 } Copy
round({ x: 0.4, y: 1.5 }); // -> { x: 0, y: 2 }
Destination object to store the result.
const result = { x: 0, y: 0 };round({ x: 0.4, y: 1.5 }, result); // result -> { x: 0, y: 2 } Copy
const result = { x: 0, y: 0 };round({ x: 0.4, y: 1.5 }, result); // result -> { x: 0, y: 2 }
Round the values of a vector.