RaveVector< T > Class Template Reference
#include <math.h>
List of all members.
Public Member Functions |
RaveVector< T > & | Cross (const RaveVector< T > &u, const RaveVector< T > &v) |
| this = u x v
|
RaveVector< T > & | Cross (const RaveVector< T > &v) |
template<class U > |
T | dot (const RaveVector< U > &v) const |
T | lengthsqr2 () const |
T | lengthsqr3 () const |
T | lengthsqr4 () const |
RaveVector< T > & | normalize () |
RaveVector< T > & | normalize3 () |
RaveVector< T > & | normalize4 () |
| operator const T * () const |
| operator T * () |
RaveVector< T > | operator* (T k) const |
template<class U > |
RaveVector< T > | operator* (const RaveVector< U > &r) const |
RaveVector< T > & | operator*= (const T k) |
template<class U > |
RaveVector< T > & | operator*= (const RaveVector< U > &r) |
template<class U > |
RaveVector< T > | operator+ (const RaveVector< U > &r) const |
template<class U > |
RaveVector< T > & | operator+= (const RaveVector< U > &r) |
template<class U > |
RaveVector< T > | operator- (const RaveVector< U > &r) const |
RaveVector< T > | operator- () const |
template<class U > |
RaveVector< T > & | operator-= (const RaveVector< U > &r) |
RaveVector< T > & | operator/= (const T _k) |
template<class U > |
RaveVector< T > & | operator= (const RaveVector< U > &r) |
T & | operator[] (int i) |
T | operator[] (int i) const |
template<class U > |
RaveVector< T > | operator^ (const RaveVector< U > &v) const |
| cross product operator
|
template<class U > |
| RaveVector (const U *pf) |
| note, it only copes 3 values!
|
template<class U > |
| RaveVector (const RaveVector< U > &vec) |
| RaveVector (T x, T y, T z, T w) |
| RaveVector (T x, T y, T z) |
| RaveVector () |
void | Set3 (T val1, T val2, T val3) |
void | Set3 (const T *pvals) |
void | Set4 (T val1, T val2, T val3, T val4) |
void | Set4 (const T *pvals) |
Public Attributes |
T | w |
T | x |
T | y |
T | z |
Friends |
template<class U > |
RaveVector< U > | operator* (double f, const RaveVector< U > &v) |
template<class U > |
RaveVector< U > | operator* (float f, const RaveVector< U > &v) |
template<class S , class U > |
std::basic_ostream< S > & | operator<< (std::basic_ostream< S > &O, const RaveVector< U > &v) |
template<class S , class U > |
std::basic_istream< S > & | operator>> (std::basic_istream< S > &I, RaveVector< U > &v) |
Detailed Description
template<class T>
class RaveVector< T >
class used for 3 and 4 dim vectors and quaternions It is better to use this for a 3 dim vector because it is 16byte aligned and SIMD instructions can be used
Definition at line 242 of file math.h.
Constructor & Destructor Documentation
template<class T>
template<class U >
template<class T>
template<class U >
note, it only copes 3 values!
Definition at line 254 of file math.h.
Member Function Documentation
this = u x v
Definition at line 298 of file math.h.
3 dim cross product, w is not touched this = this x v
Definition at line 295 of file math.h.
template<class T>
template<class U >
template<class T>
RaveVector< T >::operator const T * |
( |
|
) |
const [inline] |
template<class T>
template<class U >
template<class T>
template<class U >
template<class T>
template<class U >
template<class T>
template<class U >
template<class T>
template<class U >
template<class T>
template<class U >
template<class T>
template<class U >
template<class T>
T RaveVector< T >::operator[] |
( |
int |
i |
) |
const [inline] |
template<class T>
template<class U >
cross product operator
Definition at line 327 of file math.h.
template<class T>
void RaveVector< T >::Set3 |
( |
T |
val1, |
|
|
T |
val2, |
|
|
T |
val3 | |
|
) |
| | [inline] |
template<class T>
void RaveVector< T >::Set3 |
( |
const T * |
pvals |
) |
[inline] |
template<class T>
void RaveVector< T >::Set4 |
( |
T |
val1, |
|
|
T |
val2, |
|
|
T |
val3, |
|
|
T |
val4 | |
|
) |
| | [inline] |
template<class T>
void RaveVector< T >::Set4 |
( |
const T * |
pvals |
) |
[inline] |
Friends And Related Function Documentation
template<class T>
template<class U >
template<class T>
template<class U >
template<class T>
template<class S , class U >
std::basic_ostream<S>& operator<< |
( |
std::basic_ostream< S > & |
O, |
|
|
const RaveVector< U > & |
v | |
|
) |
| | [friend] |
template<class T>
template<class S , class U >
std::basic_istream<S>& operator>> |
( |
std::basic_istream< S > & |
I, |
|
|
RaveVector< U > & |
v | |
|
) |
| | [friend] |
Member Data Documentation
The documentation for this class was generated from the following file: