Vector4

Overview

Vector4 is a class in Aspose.3D FOSS for TypeScript.

Vector4.constructor creates a new Vector4 with default components (0,0,0,0).

This class declares 10 methods for Vector4 objects in TypeScript programs. Available methods include: constructor, equals, getItem, set, setItem, toString. Public members are accessible to any TypeScript application after installing the Aspose.3D FOSS for TypeScript package. Properties: w, x, y, z.

Properties

NameTypeAccessDescription
xnumberRead/WriteGets the x.
ynumberRead/WriteGets the y.
znumberRead/WriteGets the z.
wnumberRead/WriteGets the w.

Methods

SignatureDescription
constructor()Creates a Vector4 from a mixed first argument (FVector2, FVector3, or number) and y, z, w numbers
constructor(x: number, y: number, z: number, w: number)Calls constructor(x, y, z, w) on this Vector4 instance.
constructor(vec3: FVector3, w: number)Calls constructor(vec3, w) on this Vector4 instance.
constructor(vec: FVector2, w: number)Calls constructor(vec, w) on this Vector4 instance.
constructor(x: FVector2 | FVector3 | number, y: number, z: number, w: number)Calls constructor(x, y, z, w) on this Vector4 instance.
set(newX: number, newY: number, newZ: number, newW: number)Assigns new values to x, y, z, and w components
getItem(key: number)numberCalls getItem(key) on this Vector4 instance.
setItem(key: number, value: number)Sets the item value.
toString()stringCalls toString on this Vector4 instance.
equals(other: Vector4)booleanCalls equals(other) on this Vector4 instance.

See Also

 English