Vector4 — Aspose.3D FOSS for .NET
Overview
Aspose.ThreeD.Utilities.Vector4 is a double-precision 4-component vector. It is the type used by Mesh.ControlPoints (IList<Aspose.ThreeD.Utilities.Vector4>), PbrMaterial.BaseColor, LambertMaterial.Diffuse, and other geometry and material APIs. The w component is typically 1.0 for standard Cartesian positions.
using Aspose.ThreeD.Utilities;
var point = new Vector4(1.0, 2.0, 3.0, 1.0);
mesh.ControlPoints.Add(point);Namespace disambiguation: Two separate
Vector4structs exist in this library:
Aspose.ThreeD.Utilities.Vector4— double-precision, fieldsx,y,z,w(lowercase). This is the type used forMesh.ControlPointsand material color properties.Aspose.ThreeD.Vector4— single-precision float, fieldsX,Y,Z,W(uppercase). Used internally. Adding this type toControlPointswill cause a compile error.Always
using Aspose.ThreeD.Utilities;when working with geometry control points or material data.
Fields
| Name | Type | Description |
|---|---|---|
x | double | X component |
y | double | Y component |
z | double | Z component |
w | double | W component (homogeneous coordinate; use 1.0 for standard positions) |