molecular
Public Types | Public Member Functions | List of all members
molecular::util::Vector3T< T > Class Template Reference

Generic vector with 3 elements. More...

#include <Vector3.h>

Inheritance diagram for molecular::util::Vector3T< T >:
molecular::util::VectorTmpl< 3, Vector3T< T >, T >

Public Types

using Super = VectorTmpl< 3, Vector3T< T >, T >
 
- Public Types inherited from molecular::util::VectorTmpl< 3, Vector3T< T >, T >
typedef T T
 
using Subclass = Vector3T< T >
 

Public Member Functions

 Vector3T ()=default
 
 Vector3T (const T x, const T y, const T z)
 
 Vector3T (const T inV[3])
 
 Vector3T (const Vector2 &xy, float z)
 
T X () const
 
T Y () const
 
T Z () const
 
void Get (T *out) const
 
Vector2 Xy () const
 
Vector3Toperator-= (const Vector3T &inV)
 
Vector3Toperator+= (const Vector3T &inV)
 
Vector3T CrossProduct (const Vector3T &inV) const
 
T DotProduct (const Vector3T &inV) const
 
void SetLength (const T length)
 
T Distance (const Vector3T &inV) const
 
T DistanceSquared (const Vector3T &inV) const
 
bool IsAlmostZero (void) const
 
- Public Member Functions inherited from molecular::util::VectorTmpl< 3, Vector3T< T >, T >
 VectorTmpl ()
 
T operator[] (const int n) const
 
Toperator[] (const int n)
 
 operator const T * () const
 
 operator T * ()
 
Subclass operator* (T r) const
 Component-wise multiplication. More...
 
Subclass operator* (const VectorTmpl &in) const
 Component-wise multiplication. More...
 
Subclassoperator+= (const VectorTmpl &in)
 
Subclassoperator*= (T r)
 Component-wise in-place multiplication. More...
 
Subclassoperator*= (const VectorTmpl &in)
 Component-wise in-place multiplication. More...
 
Subclass operator/ (T r) const
 Component-wise scalar division. More...
 
Subclassoperator/= (T r)
 Component-wise in-place scalar division. More...
 
Subclassoperator/= (const VectorTmpl &in)
 Component-wise in-place division. More...
 
Subclass operator- (const VectorTmpl &in) const
 
Subclass operator- () const
 
Subclass operator+ (const VectorTmpl &in) const
 
bool operator== (const VectorTmpl &in) const
 
T LengthSquared () const
 
T Length () const
 
Subclass Normalized () const
 
T Dot (const VectorTmpl &in)
 Dot product. More...
 

Additional Inherited Members

- Protected Attributes inherited from molecular::util::VectorTmpl< 3, Vector3T< T >, T >
T v [components]
 

Detailed Description

template<typename T>
class molecular::util::Vector3T< T >

Generic vector with 3 elements.

Member Typedef Documentation

template<typename T>
using molecular::util::Vector3T< T >::Super = VectorTmpl<3, Vector3T<T>, T>

Constructor & Destructor Documentation

template<typename T>
molecular::util::Vector3T< T >::Vector3T ( )
inlinedefault
template<typename T>
molecular::util::Vector3T< T >::Vector3T ( const T  x,
const T  y,
const T  z 
)
inline
template<typename T>
molecular::util::Vector3T< T >::Vector3T ( const T  inV[3])
inline
template<typename T>
molecular::util::Vector3T< T >::Vector3T ( const Vector2 xy,
float  z 
)
inline

Member Function Documentation

template<typename T >
Vector3T< T > molecular::util::Vector3T< T >::CrossProduct ( const Vector3T< T > &  inV) const
template<typename T>
T molecular::util::Vector3T< T >::Distance ( const Vector3T< T > &  inV) const
inline
template<typename T>
T molecular::util::Vector3T< T >::DistanceSquared ( const Vector3T< T > &  inV) const
inline
template<typename T>
T molecular::util::Vector3T< T >::DotProduct ( const Vector3T< T > &  inV) const
inline
template<typename T>
void molecular::util::Vector3T< T >::Get ( T out) const
inline
template<typename T>
bool molecular::util::Vector3T< T >::IsAlmostZero ( void  ) const
inline
template<typename T >
Vector3T< T > & molecular::util::Vector3T< T >::operator+= ( const Vector3T< T > &  inV)
inline
template<typename T >
Vector3T< T > & molecular::util::Vector3T< T >::operator-= ( const Vector3T< T > &  inV)
inline
template<typename T>
void molecular::util::Vector3T< T >::SetLength ( const T  length)
inline
template<typename T>
T molecular::util::Vector3T< T >::X ( ) const
inline
template<typename T>
Vector2 molecular::util::Vector3T< T >::Xy ( ) const
inline
template<typename T>
T molecular::util::Vector3T< T >::Y ( ) const
inline
template<typename T>
T molecular::util::Vector3T< T >::Z ( ) const
inline

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