C3D Toolkit  Kernel - 109619, Vision - 2.4.0.75

The axis-vector which is attached to a fixed point. More...

#include <mb_axis3d.h>

+ Collaboration diagram for MbAxis3D:

Public Member Functions

 MbAxis3D ()
 Empty constructor. The axis is in the origin of global coordinates and coincides with the third axis of global coordinates.
 
 MbAxis3D (const MbCartPoint3D &pnt0, const MbVector3D &dir)
 Constructor by a point and a vector.
 
 MbAxis3D (const MbCartPoint3D &pnt0, const MbCartPoint3D &pnt)
 Constructor by two points.
 
 MbAxis3D (const MbPlacement3D &place, const MbCartPoint &p1, const MbCartPoint &p2)
 Constructor by a placement and two points on it.
 
 MbAxis3D (const MbAxis3D &axis)
 Constructor by another axis.
 
 MbAxis3D (const MbVector3D &v)
 The constructor by a vector.
 
void Init (const MbAxis3D &axis)
 The initialization by another axis.
 
void Init (const MbCartPoint3D &pnt0, const MbVector3D &dir)
 The initialization by a point and a vector.
 
void Init (const MbCartPoint3D &pnt0, const MbCartPoint3D &pnt)
 The initialization by two points.
 
MbAxis3DSetAxisZ (const MbVector3D &zAx)
 The initialization only by a direction with saving of the "origin".
 
The functions of a three-dimensional object
void Transform (const MbMatrix3D &)
 The transformation according to a matrix.
 
void Move (const MbVector3D &to)
 Move.
 
void Rotate (const MbAxis3D &, double angle)
 The rotation around an axis.
 
MbAxis3DDuplicate () const
 Create a copy of the element.
 
double DistanceToPoint (const MbCartPoint3D &) const
 Calculate the distance to a point.
 
double DistanceToPoint2 (const MbCartPoint3D &) const
 Calculate the square of the distance to a point.
 
double DistanceToSegment (const MbCartPoint3D &p1, const MbCartPoint3D &p2, MbCartPoint3D &p) const
 Calculate the distance to a segment.
 
double DistanceToSegment2 (const MbCartPoint3D &p1, const MbCartPoint3D &p2, MbCartPoint3D &p) const
 Calculate the square of the distance to a segment.
 
double PointProjection (const MbCartPoint3D &p0, MbCartPoint3D &proj) const
 The point projection on the axis.
 
bool Complanar (const MbPlacement3D &p, double eps=Math::angleRegion) const
 The check of complanarity.
 
bool Colinear (const MbAxis3D &a, double eps=Math::angleRegion) const
 The check of axes collinearity.
 
void SetOnPlacement (const MbPlacement3D &)
 Set the axis on a placement.
 
void Scale (double sx, double sy, double sz)
 Scaling of the axis.
 
void PointOn (const double &t, MbCartPoint3D &p) const
 Get the space point by a parameter on axis.
 
MbCartPoint3D PointOn (const double &t) const
 
Functions for access to fields
const MbCartPoint3DGetOrigin () const
 Get the axis origin.
 
const MbVector3DGetAxisZ () const
 Get the axis vector.
 
MbCartPoint3DSetOrigin ()
 Edit the axis origin.
 
MbVector3DSetAxisZ ()
 Edit the axis vector.
 
void operator= (const MbAxis3D &init)
 An assignment operator.
 
bool IsSame (const MbAxis3D &other, double accuracy) const
 Are the objects equal? More...
 

Detailed Description

The axis-vector which is attached to a fixed point.

The fixed point is the axis origin. The vector defines a positive direction. Is used for a rotation of objects in the space

Member Function Documentation

◆ IsSame()

bool MbAxis3D::IsSame ( const MbAxis3D other,
double  accuracy 
) const
inline

Are the objects equal?

The objects are equal if their data are equal with a given accuracy.

Parameters
[in]other- The object to compare.
[in]accuracy- The accuracy to compare.
Returns
Whether the objects are equal.

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