FormIt C++ API  v23.0.0 (2023.0.0)
WSM::Point3d Class Reference

Description

The Point3d class stores a point in 3D space.

The coordinates of the point are accessed via public data members, x, y, and z, or via the subscript operator, where indices 0, 1, and 2 are the x-, y-, and z- coordinates, respectively.

#include <Point3d.h>

Public Member Functions

 Point3d ()
 
 Point3d (double xx, double yy, double zz)
 
Point3d operator+ (const Point3d &p) const
 
Point3d operator+ (const Vector3d &v) const
 
Vector3d operator- (const Point3d &p) const
 
Point3d operator- (const Vector3d &v) const
 
Point3d operator- () const
 
Point3d operator* (double scalar) const
 
Point3d operator/ (double scalar) const
 
double operator% (const Vector3d &v) const
 
double operator% (const UnitVector3d &v) const
 
double operator[] (size_t index) const
 
double & operator[] (size_t index)
 
double length () const
 
double lengthSqrd () const
 
double lengthRect () const
 
double dist (const Point3d &p) const
 
double distSqrd (const Point3d &p) const
 
double distRect (const Point3d &p) const
 
bool isEqual (const Point3d &p, double epsSqrd=WSM_DISTANCE_TOL2) const
 
bool isEqualRect (const Point3d &p, double epsRect=WSM_DISTANCE_TOL) const
 
void set (double xx, double yy, double zz)
 
void zero ()
 
Point3dscale (const Vector3d &v)
 
Point3d getScaled (const Vector3d &v) const
 
void operator+= (const Point3d &p)
 
void operator+= (const Vector3d &v)
 
void operator-= (const Point3d &p)
 
void operator-= (const Vector3d &v)
 
void operator*= (double scalar)
 
void operator/= (double scalar)
 
void operator*= (const Transf3d &)
 
Point3d project (const Transf3d &) const
 
bool isBetween (const Point3d &p1, const Point3d &p2) const
 Returns true iff this point (that is assumed to lie on the line defined by the two points p1, p2) is between the two given points or is coincident with one of the points. More...
 
bool isValid () const
 
Vector3d toVector3d () const
 

Public Attributes

double x
 
double y
 
double z
 

Static Public Attributes

static const Point3d kNull
 

Constructor & Destructor Documentation

WSM::Point3d::Point3d ( )
inline
WSM::Point3d::Point3d ( double  xx,
double  yy,
double  zz 
)
inline

Member Function Documentation

double WSM::Point3d::dist ( const Point3d p) const
inline
double WSM::Point3d::distRect ( const Point3d p) const
inline
double WSM::Point3d::distSqrd ( const Point3d p) const
inline
Point3d WSM::Point3d::getScaled ( const Vector3d v) const
inline
bool WSM::Point3d::isBetween ( const Point3d p1,
const Point3d p2 
) const

Returns true iff this point (that is assumed to lie on the line defined by the two points p1, p2) is between the two given points or is coincident with one of the points.

bool WSM::Point3d::isEqual ( const Point3d p,
double  epsSqrd = WSM_DISTANCE_TOL2 
) const
inline
bool WSM::Point3d::isEqualRect ( const Point3d p,
double  epsRect = WSM_DISTANCE_TOL 
) const
inline
bool WSM::Point3d::isValid ( ) const
inline
double WSM::Point3d::length ( ) const
inline
double WSM::Point3d::lengthRect ( ) const
inline
double WSM::Point3d::lengthSqrd ( ) const
inline
double WSM::Point3d::operator% ( const Vector3d v) const
inline
double WSM::Point3d::operator% ( const UnitVector3d v) const
inline
Point3d WSM::Point3d::operator* ( double  scalar) const
inline
void WSM::Point3d::operator*= ( double  scalar)
inline
void WSM::Point3d::operator*= ( const Transf3d )
Point3d WSM::Point3d::operator+ ( const Point3d p) const
inline
Point3d WSM::Point3d::operator+ ( const Vector3d v) const
inline
void WSM::Point3d::operator+= ( const Point3d p)
inline
void WSM::Point3d::operator+= ( const Vector3d v)
inline
Vector3d WSM::Point3d::operator- ( const Point3d p) const
inline
Point3d WSM::Point3d::operator- ( const Vector3d v) const
inline
Point3d WSM::Point3d::operator- ( ) const
inline
void WSM::Point3d::operator-= ( const Point3d p)
inline
void WSM::Point3d::operator-= ( const Vector3d v)
inline
Point3d WSM::Point3d::operator/ ( double  scalar) const
inline
void WSM::Point3d::operator/= ( double  scalar)
inline
double WSM::Point3d::operator[] ( size_t  index) const
inline
double& WSM::Point3d::operator[] ( size_t  index)
inline
Point3d WSM::Point3d::project ( const Transf3d ) const
Point3d& WSM::Point3d::scale ( const Vector3d v)
inline
void WSM::Point3d::set ( double  xx,
double  yy,
double  zz 
)
inline
Vector3d WSM::Point3d::toVector3d ( ) const
inline
void WSM::Point3d::zero ( )
inline

Member Data Documentation

const Point3d WSM::Point3d::kNull
static
double WSM::Point3d::x
double WSM::Point3d::y
double WSM::Point3d::z

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