Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members  

gul::hpoint Class Template Reference

#include <gul_types.h>

List of all members.

Public Methods

weight () const
 hpoint ()
template<class T2>  hpoint (const T2 &ax, const T2 &ay, const T2 &az, const T2 &aw)
template<class T2> hpoint< T > & operator= (const point< T2 > &a)
template<class T2> hpoint< T > & operator= (const point2< T2 > &a)
template<class T2> hpoint< T > & operator= (const hpoint2< T2 > &a)
hpoint< T > & operator+= (const hpoint< T > &a)
hpoint< T > & operator-= (const hpoint< T > &a)
hpoint< T > & operator *= (T &a)
const T & operator[] (size_t i) const
 operator vec4 () const

Static Public Methods

int dim ()
bool hom ()

Public Attributes

x
y
z
w

template<class T>
class gul::hpoint< T >


Constructor & Destructor Documentation

template<class T>
gul::hpoint< T >::hpoint   [inline]
 

template<class T>
template<class T2>
gul::hpoint< T >::hpoint const T2 &    ax,
const T2 &    ay,
const T2 &    az,
const T2 &    aw
[inline]
 


Member Function Documentation

template<class T>
int gul::hpoint< T >::dim   [inline, static]
 

Definition at line 1008 of file gul_types.h.

01008 { return 4; }

template<class T>
bool gul::hpoint< T >::hom   [inline, static]
 

Definition at line 1009 of file gul_types.h.

01009 { return true; }

template<class T>
hpoint<T>& gul::hpoint< T >::operator *= T &    a [inline]
 

Definition at line 1057 of file gul_types.h.

References w, x, y, and z.

01058   {
01059     x *= a; y *= a; z *= a; w *= a;
01060     return *this;
01061   }

template<class T>
gul::hpoint< T >::operator vec4   const [inline]
 

Definition at line 1064 of file gul_types.h.

References w, x, y, and z.

01065   {
01066     vec4<T> v;
01067     v[0] = x; v[1] = y; v[2] = z; v[3] = w;
01068     return v;
01069   }

template<class T>
hpoint<T>& gul::hpoint< T >::operator+= const hpoint< T > &    a [inline]
 

Definition at line 1047 of file gul_types.h.

References w, x, y, and z.

01048   {
01049     x += a.x; y += a.y; z += a.z; w += a.w;
01050     return *this;
01051   }

template<class T>
hpoint<T>& gul::hpoint< T >::operator-= const hpoint< T > &    a [inline]
 

Definition at line 1052 of file gul_types.h.

References w, x, y, and z.

01053   {
01054     x -= a.x; y -= a.y; z -= a.z; w -= a.w;
01055     return *this;
01056   }

template<class T>
template<class T2>
hpoint<T>& gul::hpoint< T >::operator= const hpoint2< T2 > &    a [inline]
 

Definition at line 1039 of file gul_types.h.

References w, x, y, and z.

01040   { 
01041     x = (T)a.x;
01042     y = (T)a.y; 
01043     z = (T)0; 
01044     w = (T)a.w; 
01045     return *this;
01046   }

template<class T>
template<class T2>
hpoint<T>& gul::hpoint< T >::operator= const point2< T2 > &    a [inline]
 

Definition at line 1030 of file gul_types.h.

References w, x, y, and z.

01031   { 
01032     x = (T)a.x;
01033     y = (T)a.y; 
01034     z = (T)0; 
01035     w = (T)1; 
01036     return *this; 
01037   }

template<class T>
template<class T2>
hpoint<T>& gul::hpoint< T >::operator= const point< T2 > &    a [inline]
 

Definition at line 1021 of file gul_types.h.

References w, x, y, and z.

01022   { 
01023     x = (T)a.x;
01024     y = (T)a.y; 
01025     z = (T)a.z; 
01026     w = (T)1; 
01027     return *this; 
01028   }

template<class T>
const T& gul::hpoint< T >::operator[] size_t    i const [inline]
 

Definition at line 1062 of file gul_types.h.

References x.

01062 { return (&x)[i]; }

template<class T>
T gul::hpoint< T >::weight   const [inline]
 

Definition at line 1010 of file gul_types.h.

References w, x, y, and z.

01010 { return w; }


Member Data Documentation

template<class T>
T gul::hpoint::w
 

Definition at line 1007 of file gul_types.h.

Referenced by operator *=(), operator vec4(), operator+=(), operator-=(), operator=(), and weight().

template<class T>
T gul::hpoint::x
 

Definition at line 1004 of file gul_types.h.

Referenced by operator *=(), operator vec4(), operator+=(), operator-=(), operator=(), operator[](), and weight().

template<class T>
T gul::hpoint::y
 

Definition at line 1005 of file gul_types.h.

Referenced by operator *=(), operator vec4(), operator+=(), operator-=(), operator=(), and weight().

template<class T>
T gul::hpoint::z
 

Definition at line 1006 of file gul_types.h.

Referenced by operator *=(), operator vec4(), operator+=(), operator-=(), operator=(), and weight().


The documentation for this class was generated from the following file:
Generated on Mon Jan 21 04:17:57 2002 for GUL 0.6 - Geometry Utility Library by doxygen1.2.13.1 written by Dimitri van Heesch, © 1997-2001