class Vec
Background
The Vec class defines the basic three-dimensional vector and point class
used by Scenome Platform. It is based on the Coord type. The class provides
constructors and operators for covenient use, and useful vector functions,
such as rotation, measurement, dot and vector products, and others.
Some methods, like Distance2, are provided explicitly for reliable or fast
calculation of commonly useful data.
Constructors, Destructors, and Type Methods
- Vec()
- Vec( const Vec & a, const Vec & b )
- Vec( const Coord ix, const Coord iy, const Coord iz )
- Vec( const Vec & iv )
Persistence, Storage, and Transmission Methods
Inline Direct Member Access Methods
- inline Coord * GetElements()
- inline const Coord * GetElementsConst() const
- inline Coord * GetV()
- inline Coord & operator []( int index )
- inline const Coord operator []( int index ) const
- inline void Set( Coord p_fX, Coord p_fY, Coord p_fZ )
- inline void SetXY( Coord p_fX, Coord p_fY )
- inline void Swap( Vec & p_rvV )
- inline Coord & X()
- inline Coord & Y()
- inline Coord & Z()
Scalar Operators
Comparison Operators
Vector Operators
Rotation Methods
Vector Product Methods
Geometric Methods
- Vec & Blend( const Vec & vOther, Coord percentOther )
- Vec & Blend( const Vec & a, const Vec & b, Coord percentA )
- void Blend( const Vec & p_rvU, const Vec & p_rvV, Coord p_fU, Coord p_fV )
- void Blend( const Vec & p_rvO, const Vec & p_rvU, const Vec & p_rvV, Coord p_fU, Coord p_fV )
- Coord Distance( const Vec & v2 ) const
- Coord Distance2( const Vec & v2 ) const
- Coord DistanceToLine( const Vec & a, const Vec & b )
- Coord DistanceToRay( const Vec & r )
- void Negate()
- Vec & ProjectFrom( const Vec & from )
- Vec & ProjectOnto( const Vec & onto )
- Coord ProjectScale( const Vec & v2 ) const
- Coord TriArea( const Vec & b, const Vec & c )
Length Methods
Helper methods
Allocation Operators
Vector Data
| Declaration | Documentation If Applicable |
| Coord v[3] | This data member stores the x, y, and z coordinates of the vector. |