![]() |
Polygon Crucher SDK - Documentation
Documentation
|
The class defines an x, y, z 3D point which can use int, float or double. More...
The class defines an x, y, z 3D point which can use int, float or double.
| TYPE | can be int (C3DPointI), float (C3DPoint or C3DPointF) or double (C3DPointD) |
#include <3DPoint.h>
Public Member Functions | |
| C3DTPoint (TYPE *val) | |
| C3DTPoint (int refx, int refy, int refz) | |
| C3DTPoint (float refx, float refy, float refz) | |
| C3DTPoint (double refx, double refy, double refz) | |
| C3DTPoint (const C3DTPoint &pt) | |
| C3DTPoint (const C3DTPoint &pt, const C3DTVector< TYPE > &vect, bool add) | |
| if add = true, the point is point = pt+vect, if add = false, point = pt-vect | |
| unsigned int | SizeOf () const |
| C3DPointI | Floor () const |
| C3DPointI | Ceil () const |
| void | Init (TYPE x=(TYPE) 0.0, TYPE y=(TYPE) 0, TYPE z=(TYPE) 0) |
| void | Swap (unsigned int swapMode) |
| void | SubstractTo (const C3DTPoint &pt) |
| return this = pt-this, instead this = this-pt. This can be used for fast computation (using the standard operator return a C3DPointT) | |
| void | Offset (TYPE value) |
| Add value to x, y, z. | |
| bool | IsAnormal () const |
| either infinite or nan. Zero and denormalized value are allowed. | |
| bool | IsInfinite () const |
| Check if one of the coordinate has inf value. | |
| bool | IsNan (bool resetToZero=false) |
| Check if one of the coordinate has nan value. resetToZero nan = true, reset coordinates to zero if any. | |
| virtual void | To4DPoint (C4DPoint &pt) const |
| void | SetValues (const TYPE *values3t) |
| Set point from 3 TYPE. | |
| void | GetFloat (float *values3f) const |
| Get point and fill 3 floats. | |
| void | SetFloat (const float *values3f) |
| Set point from 3 floats. | |
| void | GetDouble (double *values3d) const |
| Get point and fill 3 doubles. | |
| void | SetDouble (const double *values3d) |
| Set point from 3 doubles. | |
| virtual CPt & | operator= (const C4DPoint &pt) |
| virtual void | Serialize (CXArchive &ar) |
| virtual CPt & | operator= (const CPt &refpoint) |
| template<class TYPE2 > | |
| C3DTPoint< TYPE > & | operator= (const C3DTPoint< TYPE2 > &pt) |
Access functions | |
Get access to the 3D point x, y, z values | |
| TYPE & | operator[] (int i) |
| const TYPE & | operator[] (int i) const |
| TYPE * | ValPtr () |
| const TYPE * | ValPtr () const |
Operators | |
| double | operator* (const C4DTVector< TYPE > &vect) const |
| C3DTPoint | operator* (double value) const |
| double | Mult (const double &xx, const double &yy, const double &zz) const |
| C3DTPoint & | operator= (const C3DTPoint &src) |
| C3DTPoint & | operator= (const C3DTVector< TYPE > &vect) |
| C3DTPoint | operator- (const C3DTVector< TYPE > &vect1) const |
| C3DTPoint | operator+ (const C3DTVector< TYPE > &vect1) const |
| C3DTPoint | operator+ (const C3DTPoint &pt1) const |
| C3DTPoint | operator- (const C3DTPoint &pt1) const |
| C3DTPoint | operator+ (const C4DTVector< TYPE > &pt1) const |
| C3DTPoint | operator/ (double weight) const |
| C3DTPoint & | operator-= (const C3DTPoint &pt) |
| C3DTPoint & | operator+= (const C3DTPoint &pt) |
| C3DTPoint & | operator-= (const C3DTVector< TYPE > &pt) |
| C3DTPoint & | operator+= (const C3DTVector< TYPE > &pt) |
| C3DTPoint & | operator*= (double weight) |
| C3DTPoint & | operator/= (double weight) |
| bool | operator== (const C3DTPoint &src) const |
| bool | operator!= (const C3DTPoint &src) const |
Mix type conversion (C3DTPoint<float> to C3DTPoint<double> for example) | |
| template<class TYPE2 > | |
| C3DTPoint (const C3DTPoint< TYPE2 > &pt) | |
| template<class TYPE2 > | |
| C3DTPoint (const C3DTVector< TYPE2 > &pt) | |
| template<class TYPE2 > | |
| C3DTPoint & | operator= (const C3DTPoint< TYPE2 > &pt) |
Public Member Functions inherited from CPt | |
| unsigned int | GetFlags () const |
| void | SetFlags (unsigned int flags) |
| void | SetFlag (POINT_PROPERTIES flag, bool set) |
| void | SetFlags (unsigned int flags, bool set) |
| bool | IsFlagSet (POINT_PROPERTIES flag) const |
| bool | IsOneFlagSet (int flag) const |
Public Attributes | |
| TYPE | x |
| TYPE | y |
| TYPE | z |
Friends | |
| class | C3DPointList |
Implements CPt.
Reimplemented from CPt.
Reimplemented from CPt.
Implements CPt.