Skip to content

@orillusion/core


Class: Navi3DTriangle

Defined in: src/math/navigation/Navi3DTriangle.ts:11

Vector 3D

Extends

Implements

Constructors

Constructor

new Navi3DTriangle(Id, edgeA, edgeB, edgeC): Navi3DTriangle

Defined in: src/math/navigation/Navi3DTriangle.ts:62

Parameters

Id

number

edgeA

Navi3DEdge

edgeB

Navi3DEdge

edgeC

Navi3DEdge

Returns

Navi3DTriangle

Overrides

Vector3.constructor

Properties

MAX

readonly static MAX: Vector3

Defined in: src/math/Vector3.ts:11

Vector maximum

Inherited from

Vector3.MAX


MIN

readonly static MIN: Vector3

Defined in: src/math/Vector3.ts:16

Vector minimum

Inherited from

Vector3.MIN


SAFE_MAX

readonly static SAFE_MAX: Vector3

Defined in: src/math/Vector3.ts:21

Vector maximum integer value

Inherited from

Vector3.SAFE_MAX


SAFE_MIN

readonly static SAFE_MIN: Vector3

Defined in: src/math/Vector3.ts:26

Vector minimum integer value

Inherited from

Vector3.SAFE_MIN


X_AXIS

readonly static X_AXIS: Vector3

Defined in: src/math/Vector3.ts:31

X axis positive axis coordinate (1, 0, 0).

Inherited from

Vector3.X_AXIS


neg_X_AXIS

readonly static neg_X_AXIS: Vector3

Defined in: src/math/Vector3.ts:36

The X-axis is negative (-1, 0, 0).

Inherited from

Vector3.neg_X_AXIS


Y_AXIS

readonly static Y_AXIS: Vector3

Defined in: src/math/Vector3.ts:41

The y axis defined as a Vector3 object with coordinates (0,1,0).

Inherited from

Vector3.Y_AXIS


Z_AXIS

readonly static Z_AXIS: Vector3

Defined in: src/math/Vector3.ts:46

The z axis defined as a Vector3 object with coordinates (0,0,1).

Inherited from

Vector3.Z_AXIS


x

x: number = 0

Defined in: src/math/Vector3.ts:148

The first element of a Vector3 object, such as the x coordinate of a point in the three-dimensional space. The default value is 0.

Inherited from

Vector3.x


y

y: number = 0

Defined in: src/math/Vector3.ts:154

The second element of a Vector3 object, such as the y coordinate of a point in the three-dimensional space. The default value is 0.

Inherited from

Vector3.y


z

z: number = 0

Defined in: src/math/Vector3.ts:160

The third element of a Vector3 object, such as the y coordinate of a point in the three-dimensional space. The default value is 0.

Inherited from

Vector3.z


w

w: number = 1

Defined in: src/math/Vector3.ts:167

The z component of the vector, A three-dimensional position or projection that can be used as a perspective projection We can also do w in the quaternion

Inherited from

Vector3.w


f

f: number = 0

Defined in: src/math/navigation/Navi3DTriangle.ts:29


gg

gg: number = 0

Defined in: src/math/navigation/Navi3DTriangle.ts:31


h

h: number = 0

Defined in: src/math/navigation/Navi3DTriangle.ts:33


parent

parent: Navi3DTriangle

Defined in: src/math/navigation/Navi3DTriangle.ts:35


costMultiplier

costMultiplier: number = 1.0

Defined in: src/math/navigation/Navi3DTriangle.ts:37


openId

openId: number = 0

Defined in: src/math/navigation/Navi3DTriangle.ts:39


closeId

closeId: number = 0

Defined in: src/math/navigation/Navi3DTriangle.ts:41

Accessors

ZERO

Get Signature

get static ZERO(): Vector3

Defined in: src/math/Vector3.ts:91

Returns a new vector with zero x, y, and z components

Returns

Vector3

Inherited from

Vector3.ZERO


ONE

Get Signature

get static ONE(): Vector3

Defined in: src/math/Vector3.ts:98

Returns a new vector whose x, y, and z components are all 1

Returns

Vector3

Inherited from

Vector3.ONE


LEFT

Get Signature

get static LEFT(): Vector3

Defined in: src/math/Vector3.ts:105

Returns a new vector pointing to the left, x is -1, y is 0, and z is 0

Returns

Vector3

Inherited from

Vector3.LEFT


Get Signature

get static RIGHT(): Vector3

Defined in: src/math/Vector3.ts:112

Returns a new vector pointing in the right direction, where x is 1, y is 0, and z is 0

Returns

Vector3

Inherited from

Vector3.RIGHT


UP

Get Signature

get static UP(): Vector3

Defined in: src/math/Vector3.ts:119

Returns a new vector pointing upwards, that is, x equals 0, y equals 1, and z equals 0

Returns

Vector3

Inherited from

Vector3.UP


DOWN

Get Signature

get static DOWN(): Vector3

Defined in: src/math/Vector3.ts:126

Returns a new vector pointing down, where x is 0, y is -1, and z is 0

Returns

Vector3

Inherited from

Vector3.DOWN


BACK

Get Signature

get static BACK(): Vector3

Defined in: src/math/Vector3.ts:133

Returns a new backward vector, x equals 0, y equals 0, and z equals negative 1

Returns

Vector3

Inherited from

Vector3.BACK


FORWARD

Get Signature

get static FORWARD(): Vector3

Defined in: src/math/Vector3.ts:140

Returns a new forward-pointing vector, that is, x is 0, y is 0, and z is 1

Returns

Vector3

Inherited from

Vector3.FORWARD


a

Get Signature

get a(): number

Defined in: src/math/Vector3.ts:233

get the w component

Returns

number

value of w

Set Signature

set a(value): void

Defined in: src/math/Vector3.ts:201

Set w component

Parameters
value

number

Returns

void

Inherited from

Vector3.a


r

Get Signature

get r(): number

Defined in: src/math/Vector3.ts:241

get the x component

Returns

number

value of x

Set Signature

set r(value): void

Defined in: src/math/Vector3.ts:209

Set x component

Parameters
value

number

Returns

void

Inherited from

Vector3.r


g

Get Signature

get g(): number

Defined in: src/math/Vector3.ts:249

get the y component

Returns

number

value of y

Set Signature

set g(value): void

Defined in: src/math/Vector3.ts:217

Set the y component

Parameters
value

number

Returns

void

Inherited from

Vector3.g


b

Get Signature

get b(): number

Defined in: src/math/Vector3.ts:257

get the z component

Returns

number

value of z

Set Signature

set b(value): void

Defined in: src/math/Vector3.ts:225

Set z component

Parameters
value

number

Returns

void

Inherited from

Vector3.b


length

Get Signature

get length(): number

Defined in: src/math/Vector3.ts:264

The length of the vector, the distance from the origin (0, 0, 0) to (x, y, z)

Returns

number

Inherited from

Vector3.length


lengthSquared

Get Signature

get lengthSquared(): number

Defined in: src/math/Vector3.ts:272

You get the square of the length of the vector

Returns

number

Inherited from

Vector3.lengthSquared


position

Get Signature

get position(): this

Defined in: src/math/Vector3.ts:279

Get the current vector

Returns

this

Inherited from

Vector3.position


aabb

Get Signature

get aabb(): QuadAABB

Defined in: src/math/navigation/Navi3DTriangle.ts:43

Returns

QuadAABB

Implementation of

IQuadNode.aabb


isTriangle

Get Signature

get isTriangle(): boolean

Defined in: src/math/navigation/Navi3DTriangle.ts:58

Returns

boolean

Implementation of

IQuadNode.isTriangle


id

Get Signature

get id(): number

Defined in: src/math/navigation/Navi3DTriangle.ts:104

Returns

number


plane

Get Signature

get plane(): Plane3D

Defined in: src/math/navigation/Navi3DTriangle.ts:108

Returns

Plane3D

Implementation of

IQuadNode.plane


points

Get Signature

get points(): Navi3DPoint[]

Defined in: src/math/navigation/Navi3DTriangle.ts:112

Returns

Navi3DPoint[]


walkAble

Get Signature

get walkAble(): boolean

Defined in: src/math/navigation/Navi3DTriangle.ts:157

Returns

boolean


edges

Get Signature

get edges(): Navi3DEdge[]

Defined in: src/math/navigation/Navi3DTriangle.ts:161

Returns

Navi3DEdge[]

Methods

getTowPointbyDir()

static getTowPointbyDir(dir, tp1, tp2, width, aix): void

Defined in: src/math/Vector3.ts:290

Obtain a vertical line segment with width through an orientation

Parameters

dir

Vector3

tp1

Vector3

tp2

Vector3

width

number

aix

Vector3

Returns

void

Inherited from

Vector3.getTowPointbyDir


pointToLine()

static pointToLine(point1, point2, position): number

Defined in: src/math/Vector3.ts:319

Calculate the distance from the point to the line

Parameters

point1

Vector3

Starting point of line segment

point2

Vector3

End point of line segment

position

Vector3

Point position

Returns

number

Distance from a point to a line segment

Inherited from

Vector3.pointToLine


dot()

static dot(a, b): number

Defined in: src/math/Vector3.ts:353

Take the dot product of two vectors.

Parameters

a

Vector3

Vector a

b

Vector3

Vector b

Returns

number

Inherited from

Vector3.dot


getPoints()

static getPoints(total, randSeed): any[]

Defined in: src/math/Vector3.ts:357

Parameters

total

number

randSeed

number

Returns

any[]

Inherited from

Vector3.getPoints


getPointNumbers()

static getPointNumbers(total, randSeed): any[]

Defined in: src/math/Vector3.ts:366

Parameters

total

number

randSeed

number

Returns

any[]

Inherited from

Vector3.getPointNumbers


getAngle()

static getAngle(from, to): number

Defined in: src/math/Vector3.ts:380

Returns the Angle, in degrees, between the source vector and the target vector.

Parameters

from

Vector3

source vector.

to

Vector3

target vector.

Returns

number

Inherited from

Vector3.getAngle


sqrMagnitude()

static sqrMagnitude(arg0): number

Defined in: src/math/Vector3.ts:385

Parameters

arg0

Vector3

Returns

number

Inherited from

Vector3.sqrMagnitude


getZYAngle()

static getZYAngle(zd, yd): number

Defined in: src/math/Vector3.ts:389

Parameters

zd

Vector3

yd

Vector3

Returns

number

Inherited from

Vector3.getZYAngle


sub()

static sub(a, b, target?): Vector3

Defined in: src/math/Vector3.ts:399

Subtract two vectors

Parameters

a

Vector3

Vector a

b

Vector3

Vector b

target?

Vector3 = null

output vector

Returns

Vector3

Inherited from

Vector3.sub


add()

static add(a, b, target?): Vector3

Defined in: src/math/Vector3.ts:415

Add two vectors

Parameters

a

Vector3

Vector a

b

Vector3

Vector b

target?

Vector3 = null

output vector

Returns

Vector3

Inherited from

Vector3.add


multiply()

static multiply(a, b, result?): Vector3

Defined in: src/math/Vector3.ts:426

Component-wise multiply two vectors

Parameters

a

Vector3

b

Vector3

result?

Vector3

Returns

Vector3

Inherited from

Vector3.multiply


divide()

static divide(a, b, result?): Vector3

Defined in: src/math/Vector3.ts:437

Component-wise divide two vectors

Parameters

a

Vector3

b

Vector3

result?

Vector3

Returns

Vector3

Inherited from

Vector3.divide


multiplyScalar()

static multiplyScalar(a, s, result?): Vector3

Defined in: src/math/Vector3.ts:448

Multiply a vector by a scalar

Parameters

a

Vector3

s

number

result?

Vector3

Returns

Vector3

Inherited from

Vector3.multiplyScalar


addScaledVector()

static addScaledVector(a, b, s, result?): Vector3

Defined in: src/math/Vector3.ts:459

result = a + b * s

Parameters

a

Vector3

b

Vector3

s

number

result?

Vector3

Returns

Vector3

Inherited from

Vector3.addScaledVector


cross()

static cross(a, b, result?): Vector3

Defined in: src/math/Vector3.ts:470

Cross product of two vectors

Parameters

a

Vector3

b

Vector3

result?

Vector3

Returns

Vector3

Inherited from

Vector3.cross


negate()

static negate(a, result?): Vector3

Defined in: src/math/Vector3.ts:484

Negate a vector

Parameters

a

Vector3

result?

Vector3

Returns

Vector3

Inherited from

Vector3.negate


min()

static min(a, b, result?): Vector3

Defined in: src/math/Vector3.ts:495

Component-wise minimum of two vectors

Parameters

a

Vector3

b

Vector3

result?

Vector3

Returns

Vector3

Inherited from

Vector3.min


max()

static max(a, b, result?): Vector3

Defined in: src/math/Vector3.ts:506

Component-wise maximum of two vectors

Parameters

a

Vector3

b

Vector3

result?

Vector3

Returns

Vector3

Inherited from

Vector3.max


distance()

static distance(pt1, pt2): number

Defined in: src/math/Vector3.ts:549

Calculate the distance between two vectors

Parameters

pt1

Vector3

Vector 1

pt2

Vector3

Vector 2

Returns

number

number The distance between two vectors

Inherited from

Vector3.distance


squareDistance()

static squareDistance(pt1, pt2): number

Defined in: src/math/Vector3.ts:562

Calculate the square distance between two vectors

Parameters

pt1

Vector3

Vector 1

pt2

Vector3

Vector 2

Returns

number

number The square distance between two vectors

Inherited from

Vector3.squareDistance


distanceXZ()

static distanceXZ(pt1, pt2): number

Defined in: src/math/Vector3.ts:574

Calculate the distance between two vectors XZ axes

Parameters

pt1

Vector3

Vector 1

pt2

Vector3

Vector 2

Returns

number

number The distance between two vectors

Inherited from

Vector3.distanceXZ


set()

set(x, y, z, w?): Navi3DTriangle

Defined in: src/math/Vector3.ts:589

Sets the current vector x, y, z, and w components

Parameters

x

number

y

number

z

number

w?

number = 1

Returns

Navi3DTriangle

Inherited from

Vector3.set


add()

add(a): this

Defined in: src/math/Vector3.ts:600

Adds vector a to this vector (component-wise on xyz). Mutates and returns this.

Parameters

a

Vector3

Returns

this

Inherited from

Vector3.add


addVectors()

addVectors(a, b): this

Defined in: src/math/Vector3.ts:605

Set this = a + b. Ternary mutator form.

Parameters

a

Vector3

b

Vector3

Returns

this

Inherited from

Vector3.addVectors


subVectors()

subVectors(a, b): this

Defined in: src/math/Vector3.ts:609

Parameters

a

Vector3

b

Vector3

Returns

this

Inherited from

Vector3.subVectors


multiplyVectors()

multiplyVectors(a, b): this

Defined in: src/math/Vector3.ts:614

Set this = a * b component-wise.

Parameters

a

Vector3

b

Vector3

Returns

this

Inherited from

Vector3.multiplyVectors


addScalar()

addScalar(scalar): Vector3

Defined in: src/math/Vector3.ts:618

Parameters

scalar

number

Returns

Vector3

Inherited from

Vector3.addScalar


subScalar()

subScalar(scalar): Vector3

Defined in: src/math/Vector3.ts:625

Parameters

scalar

number

Returns

Vector3

Inherited from

Vector3.subScalar


min()

min(v): this

Defined in: src/math/Vector3.ts:635

Component-wise minimum with v. Mutates and returns this.

Parameters

v

Vector3

Returns

this

Inherited from

Vector3.min


max()

max(v): this

Defined in: src/math/Vector3.ts:642

Component-wise maximum with v. Mutates and returns this.

Parameters

v

Vector3

Returns

this

Inherited from

Vector3.max


distanceToSquared()

distanceToSquared(v): number

Defined in: src/math/Vector3.ts:646

Parameters

v

Vector3

Returns

number

Inherited from

Vector3.distanceToSquared


addXYZW()

addXYZW(x, y, z, w): this

Defined in: src/math/Vector3.ts:656

Adds (x, y, z, w) to each component. Mutates and returns this.

Parameters

x

number

y

number

z

number

w

number

Returns

this

Inherited from

Vector3.addXYZW


clone()

clone(): Vector3

Defined in: src/math/Vector3.ts:667

Clone a vector with the same components as the current vector

Returns

Vector3

Inherited from

Vector3.clone


decrementBy()

decrementBy(a): this

Defined in: src/math/Vector3.ts:681

Subtract two vectors and assign the result to yourself

Parameters

a

Vector3

Minus vector

Returns

this

Inherited from

Vector3.decrementBy


dotProduct()

dotProduct(a): number

Defined in: src/math/Vector3.ts:694

Calculate the dot product of two vectors and return the Angle relationship between the two vectors

Parameters

a

Vector3

The vector that you need to compute

Returns

number

number Returns the Angle relationship between two vectors

Inherited from

Vector3.dotProduct


equals()

equals(toCompare, allFour?): boolean

Defined in: src/math/Vector3.ts:716

Find whether the values of two vectors are identical

Parameters

toCompare

Vector3

The vector to compare

allFour?

boolean = false

The default parameter is 1, whether to compare the w component

Returns

boolean

A value of true if the specified Vector3 object is equal to the current Vector3 object; false if it is not equal.

Inherited from

Vector3.equals


incrementBy()

incrementBy(a): this

Defined in: src/math/Vector3.ts:736

The current vector plus is equal to the vector, plus just the x, y, and z components

Parameters

a

Vector3

vector

Returns

this

Inherited from

Vector3.incrementBy


divide()

divide(v): this

Defined in: src/math/Vector3.ts:747

Component-wise divides this vector by v. Mutates and returns this.

Parameters

v

Vector3

Returns

this

Inherited from

Vector3.divide


negate()

negate(): Navi3DTriangle

Defined in: src/math/Vector3.ts:758

Sets the current Vector3 object to its inverse. The inverse object is also considered the opposite of the original object. The value of the x, y, and z properties of the current Vector3 object is changed to -x, -y, and -z.

Returns

Navi3DTriangle

Inherited from

Vector3.negate


normalize()

normalize(thickness?): Vector3

Defined in: src/math/Vector3.ts:773

Scales the line segment between(0,0) and the current point to a set length.

Parameters

thickness?

number = 1

The scaling value. For example, if the current Vector3 object is (0,3,4), and you normalize it to 1, the point returned is at(0,0.6,0.8).

Returns

Vector3

Inherited from

Vector3.normalize


applyQuaternion()

applyQuaternion(q): Navi3DTriangle

Defined in: src/math/Vector3.ts:790

Apply the rotation quaternion

Parameters

q

any

quaternion

Returns

Navi3DTriangle

Inherited from

Vector3.applyQuaternion


applyMatrix4()

applyMatrix4(m): this

Defined in: src/math/Vector3.ts:815

Parameters

m

any

Returns

this

Inherited from

Vector3.applyMatrix4


setTo()

setTo(xa, ya, za, wa?): void

Defined in: src/math/Vector3.ts:827

Parameters

xa

number

The first element, such as the x coordinate.

ya

number

The second element, such as the y coordinate.

za

number

The third element, such as the z coordinate.

wa?

number = 1

Returns

void

Language

en_US Sets the members of Vector3 to the specified values

Inherited from

Vector3.setTo


copy()

copy(src): this

Defined in: src/math/Vector3.ts:839

Copy the components of the source vector to this vector

Parameters

src

Vector3

Source vector

Returns

this

Inherited from

Vector3.copy


sub()

sub(a): this

Defined in: src/math/Vector3.ts:858

Parameters

a

Vector3

The Vector3 object to be subtracted from the current Vector3 object.

Returns

this

A new Vector3 object that is the difference between the current Vector3 and the specified Vector3 object.

Language

en_US Subtracts the value of the x, y, and z elements of the current Vector3 object from the values of the x, y, and z elements of another Vector3 object. Returns a new Vector3.

Inherited from

Vector3.sub


multiply()

multiply(other): this

Defined in: src/math/Vector3.ts:865

Component-wise multiplies this vector by other. Mutates and returns this.

Parameters

other

Vector3

Returns

this

Inherited from

Vector3.multiply


lerp()

lerp(v0, v1, t): void

Defined in: src/math/Vector3.ts:875

Computes the linear interpolation between two Vector3, and the result is the current object

Parameters

v0

Vector3

Vector 1

v1

Vector3

Vector 2

t

number

Interpolation factor

Returns

void

Inherited from

Vector3.lerp


clamp()

clamp(min, max): Vector3

Defined in: src/math/Vector3.ts:897

The x, y, and z components of this vector are rounded upward to the nearest integers.

Parameters

min

Vector3

minimum value

max

Vector3

maximum value

Returns

Vector3

Inherited from

Vector3.clamp


toString()

toString(): string

Defined in: src/math/Vector3.ts:963

Returns the string form of the current vector

Returns

string

Inherited from

Vector3.toString


normalizeToWay2D_XY()

normalizeToWay2D_XY(): void

Defined in: src/math/Vector3.ts:979

Returns

void

Inherited from

Vector3.normalizeToWay2D_XY


toArray()

toArray(): number[]

Defined in: src/math/Vector3.ts:997

Returns

number[]

Inherited from

Vector3.toArray


copyToBytes()

copyToBytes(byte): void

Defined in: src/math/Vector3.ts:1001

Parameters

byte

DataView

Returns

void

Inherited from

Vector3.copyToBytes


cross()

cross(a): this

Defined in: src/math/Vector3.ts:1016

Cross product with another vector. Returns a new Vector3.

Parameters

a

Vector3

Returns

this

Inherited from

Vector3.cross


crossVectors()

crossVectors(a, b): this

Defined in: src/math/Vector3.ts:1020

Parameters

a

Vector3

b

Vector3

Returns

this

Inherited from

Vector3.crossVectors


multiplyScalar()

multiplyScalar(scalar): Navi3DTriangle

Defined in: src/math/Vector3.ts:1025

Parameters

scalar

number

Returns

Navi3DTriangle

Inherited from

Vector3.multiplyScalar


setFromArray()

setFromArray(array, firstElementPos?): void

Defined in: src/math/Vector3.ts:1033

Parameters

array

number[]

firstElementPos?

number = 0

Returns

void

Inherited from

Vector3.setFromArray


divideScalar()

divideScalar(scalar): this

Defined in: src/math/Vector3.ts:1042

Divides this vector by scalar. Mutates and returns this.

Parameters

scalar

number

Returns

this

Inherited from

Vector3.divideScalar


clampLength()

clampLength(min, max): this

Defined in: src/math/Vector3.ts:1049

Clamps the length of this vector into [min, max]. Mutates and returns this.

Parameters

min

number

max

number

Returns

this

Inherited from

Vector3.clampLength


setScalar()

setScalar(value): Navi3DTriangle

Defined in: src/math/Vector3.ts:1054

Parameters

value

number

Returns

Navi3DTriangle

Inherited from

Vector3.setScalar


addScaledVector()

addScaledVector(v, scale): Vector3

Defined in: src/math/Vector3.ts:1061

Parameters

v

Vector3

scale

number

Returns

Vector3

Inherited from

Vector3.addScaledVector


dot()

dot(v): number

Defined in: src/math/Vector3.ts:1071

Dot product. Canonical alias of dotProduct.

Parameters

v

Vector3

Returns

number

Inherited from

Vector3.dot


lengthSq()

lengthSq(): number

Defined in: src/math/Vector3.ts:1076

Squared length of this vector.

Returns

number

Inherited from

Vector3.lengthSq


distanceTo()

distanceTo(v): number

Defined in: src/math/Vector3.ts:1081

Euclidean distance to v.

Parameters

v

Vector3

Returns

number

Inherited from

Vector3.distanceTo


angleTo()

angleTo(v): number

Defined in: src/math/Vector3.ts:1086

Angle between this and v, in radians (range [0, π]).

Parameters

v

Vector3

Returns

number

Inherited from

Vector3.angleTo


lerpVectors()

lerpVectors(v1, v2, alpha): this

Defined in: src/math/Vector3.ts:1094

Set this to v1 + (v2 - v1) * alpha. Canonical alias of lerp.

Parameters

v1

Vector3

v2

Vector3

alpha

number

Returns

this

Inherited from

Vector3.lerpVectors


setFromMatrixPosition()

setFromMatrixPosition(m): this

Defined in: src/math/Vector3.ts:1100

Set this = position column of Matrix4 m.

Parameters

m
rawData

ArrayLike<number>

Returns

this

Inherited from

Vector3.setFromMatrixPosition


setFromMatrixScale()

setFromMatrixScale(m): this

Defined in: src/math/Vector3.ts:1109

Set this = scale extracted from Matrix4 m (length of each column basis).

Parameters

m
rawData

ArrayLike<number>

Returns

this

Inherited from

Vector3.setFromMatrixScale


setFromMatrixColumn()

setFromMatrixColumn(m, index): this

Defined in: src/math/Vector3.ts:1121

Set this = column index of Matrix4 m (0, 1, 2, or 3).

Parameters

m
rawData

ArrayLike<number>

index

number

Returns

this

Inherited from

Vector3.setFromMatrixColumn


projectOnVector()

projectOnVector(v): this

Defined in: src/math/Vector3.ts:1131

Project this onto v. Mutates and returns this.

Parameters

v

Vector3

Returns

this

Inherited from

Vector3.projectOnVector


projectOnPlane()

projectOnPlane(planeNormal): this

Defined in: src/math/Vector3.ts:1139

Project this onto a plane defined by its normal (unit vector).

Parameters

planeNormal

Vector3

Returns

this

Inherited from

Vector3.projectOnPlane


reflect()

reflect(normal): this

Defined in: src/math/Vector3.ts:1145

Reflect this off a surface with the given unit normal.

Parameters

normal

Vector3

Returns

this

Inherited from

Vector3.reflect


applyMatrix3()

applyMatrix3(m): this

Defined in: src/math/Vector3.ts:1150

Apply a 3x3 matrix to this vector.

Parameters

m

{ rawData: ArrayLike<number>; } | { a: number; b: number; c: number; d: number; tx: number; ty: number; }

Returns

this

Inherited from

Vector3.applyMatrix3


applyAxisAngle()

applyAxisAngle(axis, angle): this

Defined in: src/math/Vector3.ts:1168

Apply axis-angle rotation (axis must be unit, angle in radians).

Parameters

axis

Vector3

angle

number

Returns

this

Inherited from

Vector3.applyAxisAngle


transformDirection()

transformDirection(m): this

Defined in: src/math/Vector3.ts:1178

Transform this as a direction (no translation) by Matrix4 m, then normalize.

Parameters

m
rawData

ArrayLike<number>

Returns

this

Inherited from

Vector3.transformDirection


fromArray()

fromArray(array, offset?): this

Defined in: src/math/Vector3.ts:1188

Canonical alias of setFromArray.

Parameters

array

ArrayLike<number>

offset?

number = 0

Returns

this

Inherited from

Vector3.fromArray


floor()

floor(): this

Defined in: src/math/Vector3.ts:1195

Returns

this

Inherited from

Vector3.floor


ceil()

ceil(): this

Defined in: src/math/Vector3.ts:1202

Returns

this

Inherited from

Vector3.ceil


round()

round(): this

Defined in: src/math/Vector3.ts:1209

Returns

this

Inherited from

Vector3.round


roundToZero()

roundToZero(): this

Defined in: src/math/Vector3.ts:1216

Returns

this

Inherited from

Vector3.roundToZero


random()

random(): this

Defined in: src/math/Vector3.ts:1224

Fill this with components in [0, 1).

Returns

this

Inherited from

Vector3.random


pointInsideTriangle()

static pointInsideTriangle(pt, pt0, pt1, pt2): boolean

Defined in: src/math/Vector3.ts:1255

Parameters

pt

Vector3

pt0

Vector3

pt1

Vector3

pt2

Vector3

Returns

boolean

Inherited from

Vector3.pointInsideTriangle


serialize()

static serialize(position): Vector3

Defined in: src/math/Vector3.ts:1284

Parameters

position

Vector3

Returns

Vector3

Inherited from

Vector3.serialize


initAABB()

initAABB(): void

Defined in: src/math/navigation/Navi3DTriangle.ts:47

Returns

void

Implementation of

IQuadNode.initAABB


calcGlobalQuadAABB()

calcGlobalQuadAABB(): void

Defined in: src/math/navigation/Navi3DTriangle.ts:55

Returns

void

Implementation of

IQuadNode.calcGlobalQuadAABB


addNeibour()

addNeibour(edge, triangle): void

Defined in: src/math/navigation/Navi3DTriangle.ts:116

Parameters

edge

Navi3DEdge

triangle

Navi3DTriangle

Returns

void


getNeibourTriangles()

getNeibourTriangles(list?, edgeMask?, triangleMask?): Navi3DTriangle[]

Defined in: src/math/navigation/Navi3DTriangle.ts:125

Parameters

list?

Navi3DTriangle[] = null

edgeMask?

number = 1

triangleMask?

number = 1

Returns

Navi3DTriangle[]


getEdges()

getEdges(list?, edgeMask?): Navi3DEdge[]

Defined in: src/math/navigation/Navi3DTriangle.ts:145

Parameters

list?

Navi3DEdge[] = null

edgeMask?

number = 1

Returns

Navi3DEdge[]


testMask()

testMask(value): boolean

Defined in: src/math/navigation/Navi3DTriangle.ts:165

Parameters

value

number

Returns

boolean


getEdgeAgainstPoint()

getEdgeAgainstPoint(edge): Navi3DPoint

Defined in: src/math/navigation/Navi3DTriangle.ts:169

Parameters

edge

Navi3DEdge

Returns

Navi3DPoint


getPointAgainstEdge()

getPointAgainstEdge(point): Navi3DEdge

Defined in: src/math/navigation/Navi3DTriangle.ts:173

Parameters

point

Navi3DPoint

Returns

Navi3DEdge


getPublicEdge()

getPublicEdge(triangle): Navi3DEdge

Defined in: src/math/navigation/Navi3DTriangle.ts:177

Parameters

triangle

Navi3DTriangle

Returns

Navi3DEdge


loopPublicEdge()

loopPublicEdge(triangle): Navi3DEdge

Defined in: src/math/navigation/Navi3DTriangle.ts:189

Parameters

triangle

Navi3DTriangle

Returns

Navi3DEdge


randomPoint()

randomPoint(): Vector3

Defined in: src/math/navigation/Navi3DTriangle.ts:203

Returns

Vector3