Assimp: aiVector3t< TReal > Class Template Reference

assimp - Open Asset Import Library

aiVector3t< TReal > Class Template Reference

Represents a three-dimensional vector. More...

Public Member Functions

 aiVector3t ()
 
 aiVector3t (TReal _x, TReal _y, TReal _z)
 
 aiVector3t (TReal _xyz)
 
 aiVector3t (const aiVector3t &o)
 
bool Equal (const aiVector3t &other, TReal epsilon=1e-6) const
 
TReal Length () const
 Get the length of the vector. More...
 
aiVector3tNormalize ()
 Normalize the vector. More...
 
aiVector3tNormalizeSafe ()
 Normalize the vector with extra check for zero vectors. More...
 
template<typename TOther >
 operator aiVector3t< TOther > () const
 
bool operator!= (const aiVector3t &other) const
 
const aiVector3toperator*= (TReal f)
 
aiVector3toperator*= (const aiMatrix3x3t< TReal > &mat)
 
aiVector3toperator*= (const aiMatrix4x4t< TReal > &mat)
 
const aiVector3toperator+= (const aiVector3t &o)
 
const aiVector3toperator-= (const aiVector3t &o)
 
const aiVector3toperator/= (TReal f)
 
bool operator< (const aiVector3t &other) const
 
bool operator== (const aiVector3t &other) const
 
TReal operator[] (unsigned int i) const
 
TReal & operator[] (unsigned int i)
 
void Set (TReal pX, TReal pY, TReal pZ)
 Set the components of a vector. More...
 
TReal SquareLength () const
 Get the squared length of the vector. More...
 
const aiVector3t SymMul (const aiVector3t &o)
 Componentwise multiplication of two vectors. More...
 

Public Attributes

union {
   struct {
      TReal   x
 
      TReal   y
 
      TReal   z
 
   } 
 
   TReal   v [3]
 
}; 
 

Detailed Description

template<typename TReal>
class aiVector3t< TReal >

Represents a three-dimensional vector.

Constructor & Destructor Documentation

template<typename TReal>
aiVector3t< TReal >::aiVector3t ( )
inline
template<typename TReal>
aiVector3t< TReal >::aiVector3t ( TReal  _x,
TReal  _y,
TReal  _z 
)
inline
template<typename TReal>
aiVector3t< TReal >::aiVector3t ( TReal  _xyz)
inlineexplicit
template<typename TReal>
aiVector3t< TReal >::aiVector3t ( const aiVector3t< TReal > &  o)
inline

Member Function Documentation

template<typename TReal>
AI_FORCE_INLINE bool aiVector3t< TReal >::Equal ( const aiVector3t< TReal > &  other,
TReal  epsilon = 1e-6 
) const
template<typename TReal >
AI_FORCE_INLINE TReal aiVector3t< TReal >::Length ( ) const

Get the length of the vector.

Returns
length
template<typename TReal >
AI_FORCE_INLINE aiVector3t< TReal > & aiVector3t< TReal >::Normalize ( )

Normalize the vector.

template<typename TReal >
AI_FORCE_INLINE aiVector3t< TReal > & aiVector3t< TReal >::NormalizeSafe ( )

Normalize the vector with extra check for zero vectors.

template<typename TReal >
template<typename TOther >
aiVector3t< TReal >::operator aiVector3t< TOther > ( ) const
template<typename TReal >
AI_FORCE_INLINE bool aiVector3t< TReal >::operator!= ( const aiVector3t< TReal > &  other) const
template<typename TReal>
AI_FORCE_INLINE const aiVector3t< TReal > & aiVector3t< TReal >::operator*= ( TReal  f)
template<typename TReal>
AI_FORCE_INLINE aiVector3t< TReal > & aiVector3t< TReal >::operator*= ( const aiMatrix3x3t< TReal > &  mat)
template<typename TReal>
AI_FORCE_INLINE aiVector3t< TReal > & aiVector3t< TReal >::operator*= ( const aiMatrix4x4t< TReal > &  mat)
template<typename TReal >
AI_FORCE_INLINE const aiVector3t< TReal > & aiVector3t< TReal >::operator+= ( const aiVector3t< TReal > &  o)
template<typename TReal >
AI_FORCE_INLINE const aiVector3t< TReal > & aiVector3t< TReal >::operator-= ( const aiVector3t< TReal > &  o)
template<typename TReal>
AI_FORCE_INLINE const aiVector3t< TReal > & aiVector3t< TReal >::operator/= ( TReal  f)
template<typename TReal >
AI_FORCE_INLINE bool aiVector3t< TReal >::operator< ( const aiVector3t< TReal > &  other) const
template<typename TReal >
AI_FORCE_INLINE bool aiVector3t< TReal >::operator== ( const aiVector3t< TReal > &  other) const
template<typename TReal >
AI_FORCE_INLINE TReal aiVector3t< TReal >::operator[] ( unsigned int  i) const
template<typename TReal >
AI_FORCE_INLINE TReal & aiVector3t< TReal >::operator[] ( unsigned int  i)
template<typename TReal>
AI_FORCE_INLINE void aiVector3t< TReal >::Set ( TReal  pX,
TReal  pY,
TReal  pZ 
)

Set the components of a vector.

Parameters
pXX component
pYY component
pZZ component
template<typename TReal >
AI_FORCE_INLINE TReal aiVector3t< TReal >::SquareLength ( ) const

Get the squared length of the vector.

Returns
Square length
template<typename TReal >
AI_FORCE_INLINE const aiVector3t< TReal > aiVector3t< TReal >::SymMul ( const aiVector3t< TReal > &  o)

Componentwise multiplication of two vectors.

Note that vec*vec yields the dot product.

Parameters
oSecond factor

Member Data Documentation

union { ... }
template<typename TReal>
TReal aiVector3t< TReal >::v[3]
template<typename TReal>
TReal aiVector3t< TReal >::x
template<typename TReal>
TReal aiVector3t< TReal >::y
template<typename TReal>
TReal aiVector3t< TReal >::z
The documentation for this class was generated from the following files:
Generated on Sun Feb 21 2016 19:42:29 for Assimp by   doxygen 1.8.11