UNPKG

@fimbul-works/vec

Version:

A comprehensive TypeScript vector math library providing 2D, 3D, and 4D vector operations with a focus on performance and type safety.

7 lines (6 loc) 263 B
/** * Creates an ArrayVector3D from an object with x, y and z properties. * @param {{ x: number; y: number; z: number }} vector3D - Object with x, y and z properties * @returns {ArrayVector3D} Vector */ export const fromObject3D = ({ x, y, z }) => [x, y, z];