#include <artec/sdk/base/Point.h>

Public Types

typedef T value_type
 

Public Member Functions

 Point3 ()
 Constructor. Empty for fast points array allocation. More...
 
 Point3 (T tx, T ty, T tz)
 
 Point3 (const Point3 &ot)
 Copying constructor. More...
 
Point3operator= (const Point3 &ot)
 Assignment operator. More...
 
 Point3 (const Point2< T > &ot)
 Point2 conversion. More...
 
Point3operator= (const Point2< T > &ot)
 
 Point3 (const Point4< T > &ot)
 Point4 conversion. More...
 
Point3operator= (const Point4< T > &ot)
 
template<typename T2 >
 Point3 (const Point3< T2 > &ot)
 Type conversion. More...
 
Point3 operator- () const
 Unary minus. More...
 
 operator T * ()
 Conversion to plain form operator. More...
 
 operator const T * () const
 
double length () const
 Length of point. More...
 
double lengthSquared () const
 Square of length of point. More...
 
void normalize ()
 normalizing to unit vector in euclidean norm More...
 
Point3 normalized () const
 
bool isZero () const
 Zero checking. More...
 
void reset ()
 Reset values to default. More...
 
template<typename T2 >
Point3< T > & operator+= (const T2 &val)
 
template<typename T2 >
Point3< T > & operator-= (const T2 &val)
 
template<typename T2 >
Point3< T > & operator*= (const T2 &val)
 
template<typename T2 >
Point3< T > & operator/= (const T2 &val)
 
template<typename T2 >
Point3< T > operator+ (const T2 &val) const
 
template<typename T2 >
Point3< T > operator- (const T2 &val) const
 
template<typename T2 >
Point3< T > operator* (const T2 &val) const
 
template<typename T2 >
Point3< T > operator/ (const T2 &val) const
 
Point3operator+= (const Point3 &ot)
 
Point3operator-= (const Point3 &ot)
 
Point3operator*= (const Point3 &ot)
 
Point3operator/= (const Point3 &ot)
 
Point3 operator+ (const Point3 &p2) const
 
Point3 operator- (const Point3 &p2) const
 
Point3 operator* (const Point3 &p2) const
 
Point3 operator/ (const Point3 &p2) const
 
bool operator== (const Point3 &p2) const
 
bool operator!= (const Point3 &p2) const
 
bool operator> (const Point3 &p2) const
 
bool operator>= (const Point3 &p2) const
 
bool operator< (const Point3 &p2) const
 
bool operator<= (const Point3 &p2) const
 

Static Public Member Functions

static T dot (const Point3< T > &p1, const Point3< T > &p2)
 Inner product operator. More...
 
static Point3< T > cross (const Point3< T > &p1, const Point3< T > &p2)
 Cross product of two points. More...
 

Public Attributes

union {
   struct {
      T   x
 
      T   y
 
      T   z
 
   } 
 
   T   data [3]
 
}; 
 point data More...
 

Static Public Attributes

static const int size_ = 3
 

Detailed Description

template<typename T>
class artec::sdk::base::Point3< T >

3-dimensional point class. Coordinates are of type T.

Definition at line 21 of file Point.h.

Member Typedef Documentation

template<typename T>
typedef T artec::sdk::base::Point3< T >::value_type

Definition at line 193 of file Point.h.

Constructor & Destructor Documentation

template<typename T>
artec::sdk::base::Point3< T >::Point3 ( )
inlineexplicit

Constructor. Empty for fast points array allocation.

Definition at line 196 of file Point.h.

template<typename T>
artec::sdk::base::Point3< T >::Point3 ( tx,
ty,
tz 
)
inlineexplicit

Definition at line 198 of file Point.h.

template<typename T>
artec::sdk::base::Point3< T >::Point3 ( const Point3< T > &  ot)
inline

Copying constructor.

Definition at line 201 of file Point.h.

template<typename T>
artec::sdk::base::Point3< T >::Point3 ( const Point2< T > &  ot)
inline

Point2 conversion.

Definition at line 207 of file Point.h.

template<typename T>
artec::sdk::base::Point3< T >::Point3 ( const Point4< T > &  ot)
inline

Point4 conversion.

Definition at line 211 of file Point.h.

template<typename T>
template<typename T2 >
artec::sdk::base::Point3< T >::Point3 ( const Point3< T2 > &  ot)
inlineexplicit

Type conversion.

Definition at line 215 of file Point.h.

Member Function Documentation

template<typename T>
static Point3<T> artec::sdk::base::Point3< T >::cross ( const Point3< T > &  p1,
const Point3< T > &  p2 
)
inlinestatic

Cross product of two points.

Definition at line 276 of file Point.h.

template<typename T>
static T artec::sdk::base::Point3< T >::dot ( const Point3< T > &  p1,
const Point3< T > &  p2 
)
inlinestatic

Inner product operator.

Definition at line 270 of file Point.h.

template<typename T>
bool artec::sdk::base::Point3< T >::isZero ( ) const
inline

Zero checking.

Definition at line 313 of file Point.h.

template<typename T>
double artec::sdk::base::Point3< T >::length ( ) const
inline

Length of point.

Definition at line 286 of file Point.h.

template<typename T>
double artec::sdk::base::Point3< T >::lengthSquared ( ) const
inline

Square of length of point.

Definition at line 289 of file Point.h.

template<typename T>
void artec::sdk::base::Point3< T >::normalize ( )
inline

normalizing to unit vector in euclidean norm

Definition at line 292 of file Point.h.

template<typename T>
Point3 artec::sdk::base::Point3< T >::normalized ( ) const
inline

Definition at line 303 of file Point.h.

template<typename T>
artec::sdk::base::Point3< T >::operator const T * ( ) const
inline

Definition at line 283 of file Point.h.

template<typename T>
artec::sdk::base::Point3< T >::operator T * ( )
inline

Conversion to plain form operator.

Definition at line 282 of file Point.h.

template<typename T>
bool artec::sdk::base::Point3< T >::operator!= ( const Point3< T > &  p2) const
inline

Logical operations

Definition at line 256 of file Point.h.

template<typename T>
template<typename T2 >
Point3<T> artec::sdk::base::Point3< T >::operator* ( const T2 &  val) const
inline

Arithmetical operations with scalar type

Definition at line 228 of file Point.h.

template<typename T>
Point3 artec::sdk::base::Point3< T >::operator* ( const Point3< T > &  p2) const
inline

Arithmetical operations with point

Definition at line 243 of file Point.h.

template<typename T>
template<typename T2 >
Point3<T>& artec::sdk::base::Point3< T >::operator*= ( const T2 &  val)
inline

Arithmetical operations with scalar type

Definition at line 221 of file Point.h.

template<typename T>
Point3& artec::sdk::base::Point3< T >::operator*= ( const Point3< T > &  ot)
inline

Arithmetical operations with point

Definition at line 238 of file Point.h.

template<typename T>
template<typename T2 >
Point3<T> artec::sdk::base::Point3< T >::operator+ ( const T2 &  val) const
inline

Arithmetical operations with scalar type

Definition at line 224 of file Point.h.

template<typename T>
Point3 artec::sdk::base::Point3< T >::operator+ ( const Point3< T > &  p2) const
inline

Arithmetical operations with point

Definition at line 241 of file Point.h.

template<typename T>
template<typename T2 >
Point3<T>& artec::sdk::base::Point3< T >::operator+= ( const T2 &  val)
inline

Arithmetical operations with scalar type

Definition at line 219 of file Point.h.

template<typename T>
Point3& artec::sdk::base::Point3< T >::operator+= ( const Point3< T > &  ot)
inline

Arithmetical operations with point

Definition at line 236 of file Point.h.

template<typename T>
template<typename T2 >
Point3<T> artec::sdk::base::Point3< T >::operator- ( const T2 &  val) const
inline

Arithmetical operations with scalar type

Definition at line 226 of file Point.h.

template<typename T>
Point3 artec::sdk::base::Point3< T >::operator- ( const Point3< T > &  p2) const
inline

Arithmetical operations with point

Definition at line 242 of file Point.h.

template<typename T>
Point3 artec::sdk::base::Point3< T >::operator- ( ) const
inline

Unary minus.

Definition at line 248 of file Point.h.

template<typename T>
template<typename T2 >
Point3<T>& artec::sdk::base::Point3< T >::operator-= ( const T2 &  val)
inline

Arithmetical operations with scalar type

Definition at line 220 of file Point.h.

template<typename T>
Point3& artec::sdk::base::Point3< T >::operator-= ( const Point3< T > &  ot)
inline

Arithmetical operations with point

Definition at line 237 of file Point.h.

template<typename T>
template<typename T2 >
Point3<T> artec::sdk::base::Point3< T >::operator/ ( const T2 &  val) const
inline

Arithmetical operations with scalar type

Definition at line 230 of file Point.h.

template<typename T>
Point3 artec::sdk::base::Point3< T >::operator/ ( const Point3< T > &  p2) const
inline

Arithmetical operations with point

Definition at line 244 of file Point.h.

template<typename T>
template<typename T2 >
Point3<T>& artec::sdk::base::Point3< T >::operator/= ( const T2 &  val)
inline

Arithmetical operations with scalar type

Definition at line 222 of file Point.h.

template<typename T>
Point3& artec::sdk::base::Point3< T >::operator/= ( const Point3< T > &  ot)
inline

Arithmetical operations with point

Definition at line 239 of file Point.h.

template<typename T>
bool artec::sdk::base::Point3< T >::operator< ( const Point3< T > &  p2) const
inline

Logical operations

Definition at line 262 of file Point.h.

template<typename T>
bool artec::sdk::base::Point3< T >::operator<= ( const Point3< T > &  p2) const
inline

Logical operations

Definition at line 263 of file Point.h.

template<typename T>
Point3& artec::sdk::base::Point3< T >::operator= ( const Point3< T > &  ot)
inline

Assignment operator.

Definition at line 204 of file Point.h.

template<typename T>
Point3& artec::sdk::base::Point3< T >::operator= ( const Point2< T > &  ot)
inline

Definition at line 208 of file Point.h.

template<typename T>
Point3& artec::sdk::base::Point3< T >::operator= ( const Point4< T > &  ot)
inline

Definition at line 212 of file Point.h.

template<typename T>
bool artec::sdk::base::Point3< T >::operator== ( const Point3< T > &  p2) const
inline

Logical operations

Definition at line 252 of file Point.h.

template<typename T>
bool artec::sdk::base::Point3< T >::operator> ( const Point3< T > &  p2) const
inline

Logical operations

Definition at line 257 of file Point.h.

template<typename T>
bool artec::sdk::base::Point3< T >::operator>= ( const Point3< T > &  p2) const
inline

Logical operations

Definition at line 258 of file Point.h.

template<typename T>
void artec::sdk::base::Point3< T >::reset ( )
inline

Reset values to default.

Definition at line 316 of file Point.h.

Member Data Documentation

union { ... }

point data

template<typename T>
T artec::sdk::base::Point3< T >::data[3]

Definition at line 328 of file Point.h.

template<typename T>
const int artec::sdk::base::Point3< T >::size_ = 3
static

Definition at line 331 of file Point.h.

template<typename T>
T artec::sdk::base::Point3< T >::x

Definition at line 325 of file Point.h.

template<typename T>
T artec::sdk::base::Point3< T >::y

Definition at line 325 of file Point.h.

template<typename T>
T artec::sdk::base::Point3< T >::z

Definition at line 325 of file Point.h.


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