FIFE  2008.0
FIFE::PointType3D< T > Class Template Reference

#include <point.h>

Inheritance diagram for FIFE::PointType3D< T >:
Inheritance graph
Collaboration diagram for FIFE::PointType3D< T >:
Collaboration graph

Public Member Functions

 PointType3D (T _x=0, T _y=0, T _z=0)
 
 PointType3D (const PointType3D< T > &rhs)
 
PointType3D< T > operator+ (const PointType3D< T > &p) const
 
PointType3D< T > operator- (const PointType3D< T > &p) const
 
PointType3D< T > & operator+= (const PointType3D< T > &p)
 
PointType3D< T > & operator-= (const PointType3D< T > &p)
 
PointType3D< T > operator* (const T &i) const
 
PointType3D< T > operator/ (const T &i) const
 
bool operator== (const PointType3D< T > &p) const
 
bool operator!= (const PointType3D< T > &p) const
 
length () const
 
void normalize ()
 
void set (T _x, T _y, T _z)
 

Detailed Description

template<typename T>
class FIFE::PointType3D< T >

A 3D Point

This is a small helper class to aid in 3d vector arithmetics.

See also
Rect

Definition at line 202 of file point.h.

Constructor & Destructor Documentation

template<typename T>
FIFE::PointType3D< T >::PointType3D ( _x = 0,
_y = 0,
_z = 0 
)
inlineexplicit

Constructor

Creates a with 0 as default values.

Definition at line 215 of file point.h.

template<typename T>
FIFE::PointType3D< T >::PointType3D ( const PointType3D< T > &  rhs)
inline

Copy Constructor

Definition at line 220 of file point.h.

Member Function Documentation

template<typename T>
T FIFE::PointType3D< T >::length ( ) const
inline

Return length

Definition at line 279 of file point.h.

Referenced by FIFE::PointType3D< double >::normalize().

Here is the caller graph for this function:

template<typename T>
void FIFE::PointType3D< T >::normalize ( )
inline

Normalizes the point

Definition at line 287 of file point.h.

template<typename T>
bool FIFE::PointType3D< T >::operator!= ( const PointType3D< T > &  p) const
inline

Equality comparision

Definition at line 273 of file point.h.

template<typename T>
PointType3D<T> FIFE::PointType3D< T >::operator* ( const T &  i) const
inline

Scalar multiplication with an integer value

Definition at line 255 of file point.h.

template<typename T>
PointType3D<T> FIFE::PointType3D< T >::operator+ ( const PointType3D< T > &  p) const
inline

Vector addition

Definition at line 225 of file point.h.

template<typename T>
PointType3D<T>& FIFE::PointType3D< T >::operator+= ( const PointType3D< T > &  p)
inline

Vector inplace addition

Definition at line 237 of file point.h.

template<typename T>
PointType3D<T> FIFE::PointType3D< T >::operator- ( const PointType3D< T > &  p) const
inline

Vector substraction

Definition at line 231 of file point.h.

template<typename T>
PointType3D<T>& FIFE::PointType3D< T >::operator-= ( const PointType3D< T > &  p)
inline

Vector inplace substraction

Definition at line 246 of file point.h.

template<typename T>
PointType3D<T> FIFE::PointType3D< T >::operator/ ( const T &  i) const
inline

Scalar division with an integer value

Definition at line 261 of file point.h.

template<typename T>
bool FIFE::PointType3D< T >::operator== ( const PointType3D< T > &  p) const
inline

Equality comparision

Definition at line 267 of file point.h.

template<typename T>
void FIFE::PointType3D< T >::set ( _x,
_y,
_z 
)
inline

Sets the x, y and z coordinates of the 3D point

Definition at line 305 of file point.h.


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