GL Studio C++ Runtime API
PreciseVertex Class Reference

#include <gls_3d_cable.h>

Inheritance diagram for PreciseVertex:
VertexNoColor

Public Member Functions

 PreciseVertex (const Vector &vector)
 
 PreciseVertex (float x, float y, float z)
 
void NearZero ()
 
void Normalize ()
 
bool operator== (const VertexNoColor &arg) const
 
bool operator!= (const VertexNoColor &arg) const
 
- Public Member Functions inherited from VertexNoColor
 VertexNoColor ()
 
 VertexNoColor (float _x, float _y, float _z)
 
float Distance3Squared (const VertexNoColor &v) const
 
float DistanceFromLineSquared (const float startx, const float starty, const float startz, const VertexNoColor &direction) const
 
float Distance3 (const VertexNoColor &v) const
 
float Distance2Squared (const VertexNoColor &v) const
 
float Distance2 (const VertexNoColor &v) const
 
VertexNoColor operator+ (const VertexNoColor &arg) const
 
VertexNoColor operator- () const
 
VertexNoColor operator* (const float s) const
 
VertexNoColoroperator*= (const float s)
 
VertexNoColor operator/ (const float s) const
 
VertexNoColoroperator/= (const float s)
 
VertexNoColoroperator+= (const VertexNoColor &arg)
 
VertexNoColor operator- (const VertexNoColor &arg) const
 
VertexNoColoroperator-= (const VertexNoColor &arg)
 
bool operator== (const VertexNoColor &arg) const
 
bool operator!= (const VertexNoColor &arg) const
 
VertexNoColor operator* (const VertexNoColor &arg) const
 
VertexNoColor Rotate (const float angle) const
 
VertexNoColor Rotate (const VertexNoColor &orig, const float angle) const
 
VertexNoColor Rotate (const VertexNoColor &orig, const float angle, const int axis) const
 
VertexNoColor Rotate (const VertexNoColor &orig, const float angle, const Vector &r) const
 
void Normalize ()
 
float Magnitude () const
 
float MagnitudeSquared () const
 
VertexNoColor CrossProduct (const VertexNoColor &w) const
 
float DotProduct (const VertexNoColor &w) const
 
float AngleToVector (const VertexNoColor &arg) const
 
bool PointInTriangle (const VertexNoColor &a, const VertexNoColor &b, const VertexNoColor &c) const
 
bool CloseTo (const VertexNoColor &arg, float tolerance=0.0001f) const
 
float DistanceFromLine (const VertexNoColor &start, const VertexNoColor &direction) const
 
VertexNoColor ProjectPointToLine (const VertexNoColor &origin, const VertexNoColor &direction) const
 

Additional Inherited Members

- Public Attributes inherited from VertexNoColor
float x
 The X component.
 
float y
 The Y component.
 
float z
 The Z component.
 

Detailed Description

The PreciseVertex class. Uses fuzzy floating point comparison rather than exact matches.

Constructor & Destructor Documentation

◆ PreciseVertex() [1/2]

PreciseVertex ( const Vector vector)
inline

Constructor from Vector

Parameters
vectorThe vector to construct from.

◆ PreciseVertex() [2/2]

PreciseVertex ( float  x,
float  y,
float  z 
)
inline

Constructor from three floats

Parameters
xThe x component to construct from.
yThe y component to construct from.
zThe z component to construct from.

Member Function Documentation

◆ NearZero()

void NearZero ( )
inline

If the values are near zero, force them to be Zero!

Precondition
Postcondition

◆ Normalize()

void Normalize ( )
inline

Normalizes the vector into a unit vector

◆ operator!=()

bool operator!= ( const VertexNoColor arg) const
inline

Determines if the vertex is identical to the supplied vertex, ignoring color

Parameters
argvertex to compare to
Returns
TRUE if equal, else FALSE

◆ operator==()

bool operator== ( const VertexNoColor arg) const
inline

Determines if the vertex is identical to the supplied vertex, ignoring color

Parameters
argvertex to compare to
Returns
TRUE if equal, else FALSE

The documentation for this class was generated from the following file: