---
Product: Aspose.3D
Platform: typescript
Page Type: reference
Canonical URL: https://reference.aspose.org/3d/typescript/FVector4
---

# FVector4

## Overview

`FVector4` is a class in Aspose.3D FOSS for Typescript.

FVector4.constructor creates a zero‑initialized 4‑D vector.

This class provides 5 methods for working with FVector4 objects in Typescript programs.
Available methods include: `constructor`, `equals`, `getItem`, `setItem`, `toString`.
All public members are accessible to any Typescript application after installing the Aspose.3D FOSS for Typescript package.
Properties: `w`, `x`, `y`, `z`.

## Description

`FVector4` is a class in the Aspose.3D FOSS library for TypeScript that exposes 4 methods and 4 properties for programmatic use.

Core capabilities include: `number`; `number`; `number`. These operations enable developers to integrate fvector4 functionality directly into TypeScript applications.

The class offers 5 constructor overloads, allowing flexible initialization depending on the calling context.

## Properties

| Name | Type | Access | Description |
|------|------|--------|-------------|
| `x` | `number` | Read/Write | Gets the x. |
| `y` | `number` | Read/Write | Gets the y. |
| `z` | `number` | Read/Write | Gets the z. |
| `w` | `number` | Read/Write | Gets the w. |

## Methods

| Signature | Description |
|-----------|-------------|
| `constructor()` | Creates a vector using a numeric or vector first argument and remaining components |
| `constructor(x: number, y: number, z: number, w: number)` | Creates an FVector4 with the specified x, y, z, and w float components |
| `constructor(vec3: FVector3, w: number)` | Creates an FVector4 from an FVector3 and a float w component |
| `constructor(vec2: FVector2, z: number, w: number)` | Creates an FVector4 from an FVector2 and float z and w components |
| `constructor(x: number \| FVector2 \| FVector3, y: number, z: number, w: number)` | Creates an FVector4 from a mixed first argument and remaining float components |
| `getItem(key: number)` → `number` | Returns the component value at the given index (0‑x,1‑y,2‑z,3‑w) |
| `setItem(key: number, value: number)` | Sets the item value. |
| `toString()` → `string` | Returns a string representation of this vector |
| `equals(other: FVector4)` → `boolean` | Returns true if all components match the other FVector4 |

## See Also

- [Aspose.3D — Enterprise API Reference](https://reference.aspose.com/3d/)