Vector4

Métodos

Aspose.ThreeD.Utilities.Vector4 es un double-precision 4-component vector. It is the type used by Mesh.ControlPoints (IList<Aspose.ThreeD.Utilities.Vector4>), PbrMaterial.BaseColor, LambertMaterial.Diffuse, y otras API de geometría y material. El w el componente es típicamente 1.0 para posiciones cartesianas estándar.

using Aspose.ThreeD.Utilities;

var point = new Vector4(1.0, 2.0, 3.0, 1.0);
mesh.ControlPoints.Add(point);

Desambiguación de espacio de nombres: Dos separados Vector4 estructuras existen en esta biblioteca:

  • Aspose.ThreeD.Utilities.Vector4double-precision, campos x, y, z, w (minúsculas). Este es el tipo usado para Mesh.ControlPoints y propiedades de color del material.
  • Aspose.ThreeD.Vector4flotante de precisión simple, campos X, Y, Z, W (MAYÚSCULAS). Usado internamente. Añadiendo este tipo a ControlPoints causará un error de compilación.

Methods using Aspose.ThreeD.Utilities; al trabajar con puntos de control de geometría o datos de material.

Métodos

NameTypeAccessDescription
LengthdoubleReadGets the length.
SignatureDescription
Vector4(vec: Vector3, w: double)Creates a new 4‑dimensional vector with the given x, y, z, and w components
Vector4(vec: Vector3)
Vector4(vec: FVector4)
Vector4(x: double, y: double, z: double)
Vector4(x: double, y: double, z: double, w: double)
Set(newX: double, newY: double, newZ: double)Updates the X, Y, and Z components of the vector
Set(newX: double, newY: double, newZ: double, newW: double)
Equals(obj: object)Determines whether another Vector4 has the same component values
GetHashCode()
ToString()
CompareTo(other: Vector4)Compares this vector with another Vector4 for ordering

Ver también

 Español