General purpose double quad, uses include representation of colour coordinates.
Public Fields
-
value_type _v[4]
Public Methods
-
Vec4d()
-
Vec4d(value_type x, value_type y, value_type z, value_type w)
-
Vec4d(const Vec3d& v3, value_type w)
-
inline Vec4d(const Vec4f& vec)
-
inline operator Vec4f() const
-
inline bool operator == (const Vec4d& v) const
-
inline bool operator != (const Vec4d& v) const
-
inline bool operator < (const Vec4d& v) const
-
inline value_type* ptr()
-
inline const value_type* ptr() const
-
inline void set( value_type x, value_type y, value_type z, value_type w)
-
inline value_type& operator [] (unsigned int i)
-
inline value_type operator [] (unsigned int i) const
-
inline value_type& x()
-
inline value_type& y()
-
inline value_type& z()
-
inline value_type& w()
-
inline value_type x() const
-
inline value_type y() const
-
inline value_type z() const
-
inline value_type w() const
-
inline unsigned long asABGR() const
-
inline unsigned long asRGBA() const
-
inline bool valid() const
-
inline bool isNaN() const
-
inline value_type operator * (const Vec4d& rhs) const
- dot product
-
inline Vec4d operator * (value_type rhs) const
- multiply by scalar
-
inline Vec4d& operator *= (value_type rhs)
- unary multiply by scalar
-
inline Vec4d operator / (value_type rhs) const
- divide by scalar
-
inline Vec4d& operator /= (value_type rhs)
- unary divide by scalar
-
inline Vec4d operator + (const Vec4d& rhs) const
- binary vector add
-
inline Vec4d& operator += (const Vec4d& rhs)
- unary vector add.
-
inline Vec4d operator - (const Vec4d& rhs) const
- binary vector subtract
-
inline Vec4d& operator -= (const Vec4d& rhs)
- unary vector subtract
-
inline const Vec4d operator - () const
- negation operator.
-
inline value_type length() const
- Length of the vector = sqrt( vec .
-
inline value_type length2() const
- Length squared of the vector = vec .
-
inline value_type normalize()
- normalize the vector so that it has length unity returns the previous length of the vector
Public
-
typedef double value_type
Documentation
General purpose double quad, uses include representation
of colour coordinates.
No support yet added for double * Vec4d - is it necessary?
Need to define a non-member non-friend operator* etc.
Vec4d * double is okay
- typedef double value_type
- value_type _v[4]
- Vec4d()
- Vec4d(value_type x, value_type y, value_type z, value_type w)
- Vec4d(const Vec3d& v3, value_type w)
- inline Vec4d(const Vec4f& vec)
- inline operator Vec4f() const
- inline bool operator == (const Vec4d& v) const
- inline bool operator != (const Vec4d& v) const
- inline bool operator < (const Vec4d& v) const
- inline value_type* ptr()
- inline const value_type* ptr() const
- inline void set( value_type x, value_type y, value_type z, value_type w)
- inline value_type& operator [] (unsigned int i)
- inline value_type operator [] (unsigned int i) const
- inline value_type& x()
- inline value_type& y()
- inline value_type& z()
- inline value_type& w()
- inline value_type x() const
- inline value_type y() const
- inline value_type z() const
- inline value_type w() const
- inline unsigned long asABGR() const
- inline unsigned long asRGBA() const
- inline bool valid() const
- inline bool isNaN() const
- inline value_type operator * (const Vec4d& rhs) const
- dot product
- inline Vec4d operator * (value_type rhs) const
- multiply by scalar
- inline Vec4d& operator *= (value_type rhs)
- unary multiply by scalar
- inline Vec4d operator / (value_type rhs) const
- divide by scalar
- inline Vec4d& operator /= (value_type rhs)
- unary divide by scalar
- inline Vec4d operator + (const Vec4d& rhs) const
- binary vector add
- inline Vec4d& operator += (const Vec4d& rhs)
- unary vector add. Slightly more efficient because no temporary
intermediate object
- inline Vec4d operator - (const Vec4d& rhs) const
- binary vector subtract
- inline Vec4d& operator -= (const Vec4d& rhs)
- unary vector subtract
- inline const Vec4d operator - () const
- negation operator. Returns the negative of the Vec4d
- inline value_type length() const
- Length of the vector = sqrt( vec . vec )
- inline value_type length2() const
- Length squared of the vector = vec . vec
- inline value_type normalize()
- normalize the vector so that it has length unity
returns the previous length of the vector
- This class has no child classes.
- Friends:
- inline std::ostream& operator << (std::ostream& output, const Vec4d& vec)
Alphabetic index HTML hierarchy of classes or Java
This page was generated with the help of DOC++.