FVector3

Overview

FVector3 is a class in Aspose.3D FOSS for Typescript.

FVector3.constructor creates a vector with default components (0,0,0).

Properties

NameTypeAccessDescription
xnumberRead/WriteIs the X component of the vector
ynumberRead/Write
znumberRead/Write

Methods

SignatureDescription
constructor()Creates a vector from either x value or a 2D vector and y, z
constructor(x: number, y: number, z: number)
constructor(vec2: FVector2, z: number)
constructor(x: number | FVector2, y: number, z: number)
zero()FVector3Returns a vector (0,0,0)
one()FVector3Returns a vector (1,1,1)
unitX()FVector3Returns a unit vector (1,0,0)
unitY()FVector3
unitZ()FVector3
normalize()FVector3Returns a vector with length 1 pointing in the same direction
getItem(key: number)numberReturns the component at index 0=x,1=y,2=z
setItem(key: number, value: number)
toString()stringReturns a string representation of the vector
equals(other: FVector3)booleanChecks if both vectors have identical components

See Also