6#if !defined(AFX_3DPOINT_H__CA6BC29E_FAC2_11D1_A0DE_000000000000__INCLUDED_)
7#define AFX_3DPOINT_H__CA6BC29E_FAC2_11D1_A0DE_000000000000__INCLUDED_
14#include "StringTools.h"
19BEGIN_MOOTOOLS_NAMESPACE
46 TYPE& operator[](
int i);
47 const TYPE& operator[](
int i)
const;
49 const TYPE* ValPtr()
const;
53 unsigned int SizeOf()
const;
61 double Mult(
const double&
xx,
const double&
yy,
const double&
zz)
const;
117 virtual void Dump()
const;
119 virtual bool IsKindOf(
unsigned int classid)
const;
120 virtual unsigned int ClassID()
const;
177 return HashMixValue(hash.x + HashMixValue(hash.y)) + hash.z;
186END_MOOTOOLS_NAMESPACE
190#include "3DPoint.inl"
192BEGIN_MOOTOOLS_NAMESPACE
200 return MAKE_CUSTOM_ID(
'3',
'D',
'P',
'I');
205 return MAKE_CUSTOM_ID(
'3',
'D',
'P',
'F');
210 return MAKE_CUSTOM_ID(
'3',
'D',
'P',
'D');
221 XTRACE(
_T(
"%.5f %.5f %.5f\n"), x, y, z);
227 XTRACE(
_T(
"%d %d %d\n"), x, y, z);
267 XASSERT(
pt.size == 3);
287 SWAP_VALUES(x, y,
tmp);
290 SWAP_VALUES(x, z,
tmp);
293 SWAP_VALUES(y, z,
tmp);
300 switch (
swapMode & SWAP_INVERT_FLAGS)
363 if (C3DTPoint::ClassID() == classid)
366 return CPt::IsKindOf(classid);
373 return MAKE_CUSTOM_ID(
'3',
'D',
'P',
'T');
377END_MOOTOOLS_NAMESPACE
CPt class is the base class for different class of points (C3DPoint, CUVWPoint...)
Definition 3DPointList.h:267
The class defines an x, y, z 3D point which can use int, float or double.
Definition 3DPoint.h:27
void SetValues(const TYPE *values3t)
Set point from 3 TYPE.
Definition 3DPoint.inl:88
void SetFloat(const float *values3f)
Set point from 3 floats.
Definition 3DPoint.h:320
bool IsAnormal() const
either infinite or nan. Zero and denormalized value are allowed.
Definition 3DPoint.inl:177
void SubstractTo(const C3DTPoint &pt)
return this = pt-this, instead this = this-pt. This can be used for fast computation (using the stand...
Definition 3DPoint.inl:153
void GetDouble(double *values3d) const
Get point and fill 3 doubles.
Definition 3DPoint.h:334
void SetDouble(const double *values3d)
Set point from 3 doubles.
Definition 3DPoint.h:341
bool IsInfinite() const
Check if one of the coordinate has inf value.
Definition 3DPoint.inl:186
void GetFloat(float *values3f) const
Get point and fill 3 floats.
Definition 3DPoint.h:327
void Offset(TYPE value)
Add value to x, y, z.
Definition 3DPoint.inl:169
bool IsNan(bool resetToZero=false)
Check if one of the coordinate has nan value. resetToZero nan = true, reset coordinates to zero if an...
Definition 3DPoint.inl:194
CPt base only contains some flags that are used by the derived class.
Definition Point.h:60