wgpu-matrix
    Preparing search index...

    Variable fromValues

    fromValues: (x?: number, y?: number) => number[]

    Type declaration

      • (x?: number, y?: number): number[]
      • Creates a Vec2; may be called with x, y, z to set initial values.

        Note: Since passing in a raw JavaScript array is valid in all circumstances, if you want to force a JavaScript array into a Vec2's specified type it would be faster to use

        const v = vec2.clone(someJSArray);
        

        Parameters

        • x: number = 0

          Initial x value.

        • y: number = 0

          Initial y value.

        Returns number[]

        the created vector