Home Reference Source
public class | source

Vector3

Static Method Summary

Static Public Methods
public static

add(lv: Vector3, rv: Vector3): *

add value(static version)

public static

angleOfVectors(lhv: Vector3, rhv: Vector3): *

public static

cross(lv: Vector3, rv: Vector3): *

cross product(static version)

public static

divide(vec3: Vector3, val: number): *

divide(static version)

public static

divideVector(lvec3: Vector3, rvec3: Vector3): *

divide vector(static version)

public static

dotProduct(lv: Vector3, rv: Vector3): *

dot product(static version)

public static

lengthBtw(lhv: Vector3, rhv: Vector3): *

public static

to square length(static verison)

public static

multiply(vec3: Vector3, val: number): *

multiply(static version)

public static

multiplyVector(vec3: Vector3, vec: Vector3): *

multiply vector(static version)

public static

normalize(vec3: Vector3): *

normalize(static version)

public static

subtract(lv: Vector3, rv: Vector3): *

subtract(subtract)

public static

zero(): *

Zero Vector

Constructor Summary

Public Constructor
public

constructor(x: number | TypedArray | Vector2 | Vector3 | Vector4, y: number, z: number)

Member Summary

Public Members
public get
public get

raw: *

public

v: TypedArray

public get

x: *

public set
public get

y: *

public set
public get

z: *

public set

Method Summary

Public Methods
public

add(v: Vector3): *

add value

public

clone(): *

public

cross(v: Vector3): *

cross product

public

divide(val: number): *

divide

public

divideVector(vec3: Vector3): *

divide vector

public

dotProduct(vec3: Vector3): *

dot product

public
public

length(): *

public

to square length

public

lengthTo(vec3: Vector3): *

public

multiply(val: number): *

multiply

public

multiply vector

public

normalize(): *

normalize

public

subtract(v: Vector3): *

subtract

public

toString(): *

change to string

Static Public Methods

public static add(lv: Vector3, rv: Vector3): * source

add value(static version)

Params:

NameTypeAttributeDescription
lv Vector3
rv Vector3

Return:

*

public static angleOfVectors(lhv: Vector3, rhv: Vector3): * source

Params:

NameTypeAttributeDescription
lhv Vector3
rhv Vector3

Return:

*

public static cross(lv: Vector3, rv: Vector3): * source

cross product(static version)

Params:

NameTypeAttributeDescription
lv Vector3
rv Vector3

Return:

*

public static divide(vec3: Vector3, val: number): * source

divide(static version)

Params:

NameTypeAttributeDescription
vec3 Vector3
val number

Return:

*

public static divideVector(lvec3: Vector3, rvec3: Vector3): * source

divide vector(static version)

Params:

NameTypeAttributeDescription
lvec3 Vector3
rvec3 Vector3

Return:

*

public static dotProduct(lv: Vector3, rv: Vector3): * source

dot product(static version)

Params:

NameTypeAttributeDescription
lv Vector3
rv Vector3

Return:

*

public static lengthBtw(lhv: Vector3, rhv: Vector3): * source

Params:

NameTypeAttributeDescription
lhv Vector3
rhv Vector3

Return:

*

public static lengthSquared(vec3: Vector3): * source

to square length(static verison)

Params:

NameTypeAttributeDescription
vec3 Vector3

Return:

*

public static multiply(vec3: Vector3, val: number): * source

multiply(static version)

Params:

NameTypeAttributeDescription
vec3 Vector3
val number

Return:

*

public static multiplyVector(vec3: Vector3, vec: Vector3): * source

multiply vector(static version)

Params:

NameTypeAttributeDescription
vec3 Vector3
vec Vector3

Return:

*

public static normalize(vec3: Vector3): * source

normalize(static version)

Params:

NameTypeAttributeDescription
vec3 Vector3

Return:

*

public static subtract(lv: Vector3, rv: Vector3): * source

subtract(subtract)

Params:

NameTypeAttributeDescription
lv Vector3
rv Vector3

Return:

*

public static zero(): * source

Zero Vector

Return:

*

Public Constructors

public constructor(x: number | TypedArray | Vector2 | Vector3 | Vector4, y: number, z: number) source

Params:

NameTypeAttributeDescription
x number | TypedArray | Vector2 | Vector3 | Vector4
y number
z number

Public Members

public get className: * source

public get raw: * source

public v: TypedArray source

public get x: * source

public set x: number source

public get y: * source

public set y: number source

public get z: * source

public set z: number source

Public Methods

public add(v: Vector3): * source

add value

Params:

NameTypeAttributeDescription
v Vector3

Return:

*

public clone(): * source

Return:

*

public cross(v: Vector3): * source

cross product

Params:

NameTypeAttributeDescription
v Vector3

Return:

*

public divide(val: number): * source

divide

Params:

NameTypeAttributeDescription
val number

Return:

*

public divideVector(vec3: Vector3): * source

divide vector

Params:

NameTypeAttributeDescription
vec3 Vector3

Return:

*

public dotProduct(vec3: Vector3): * source

dot product

Params:

NameTypeAttributeDescription
vec3 Vector3

Return:

*

public isEqual(vec: Vector3): boolean source

Params:

NameTypeAttributeDescription
vec Vector3

Return:

boolean

public length(): * source

Return:

*

public lengthSquared(): * source

to square length

Return:

*

public lengthTo(vec3: Vector3): * source

Params:

NameTypeAttributeDescription
vec3 Vector3

Return:

*

public multiply(val: number): * source

multiply

Params:

NameTypeAttributeDescription
val number

Return:

*

public multiplyVector(vec: Vector3): * source

multiply vector

Params:

NameTypeAttributeDescription
vec Vector3

Return:

*

public normalize(): * source

normalize

Return:

*

public subtract(v: Vector3): * source

subtract

Params:

NameTypeAttributeDescription
v Vector3

Return:

*

public toString(): * source

change to string

Return:

*