Class Vec2

A 2D vector.

Hierarchy (view full)

Implements

Constructors

Properties

byteOffset: number

The offset in bytes of the array.

Accessors

  • get buffer(): ArrayBufferLike
  • The ArrayBuffer instance referenced by the array.

    Returns ArrayBufferLike

  • get byteLength(): number
  • The length in bytes of the array.

    Returns number

  • get length(): 2
  • Returns the length of Vec.

    Returns 2

  • get valid(): boolean
  • Whether the array is still valid.

    Returns boolean

Methods

  • Computes the dot product of this vector with RHS.

    Parameters

    Returns number

  • Computes the linear interpolation between this vector and RHS.

    Parameters

    Returns this

  • Premultiplies 3x3 matrix to this.

    Parameters

    Returns this

  • Scales this vector by given factor.

    Parameters

    • factor: number

    Returns this

Generated using TypeDoc