Function setLength

  • Treat a 4D vector as a direction and set it's length

    Type Parameters

    Parameters

    • a: BaseArgType

      The vec4 to lengthen

    • len: number

      The length of the resulting vector

    • Optional dst: T

    Returns T

    The lengthened vector