C3D Toolkit
Kernel - 117982, Vision - 2.9.2.2
|
Local coordinate system in two dimensional space. More...
#include <mb_placement.h>
Public Member Functions | |
MbPlacement () | |
Default constructor. | |
MbPlacement (const MbCartPoint &, const MbDirection &, bool l=false) | |
Constructor by point and normalized direction vector. | |
MbPlacement (const MbCartPoint &, const MbVector &, const MbVector &) | |
Constructor by point and two vectors. | |
MbPlacement (const MbCartPoint &, bool, bool) | |
Constructor by point and signs of X-axis and Y-axis directions. | |
MbPlacement (const MbCartPoint &, double angle, bool l=false) | |
Constructor by point and angle. | |
MbPlacement (double x, double y, double angle) | |
Constructor by angle and coordinates of local coordinate system origin. | |
MbPlacement (const MbCartPoint &p1, const MbCartPoint &p2) | |
Constructor by two points. | |
MbPlacement (const MbPlacement &) | |
Copy-constructor. | |
MbPlacement (const MbMatrix &matr) | |
Constructor by matrix. | |
~MbPlacement () | |
The destructor. | |
void | Init () |
Make coincident with global coordinate system. | |
void | Init (const MbPlacement &init) |
Initialize by given local coordinate system. | |
void | Init (const MbCartPoint &initOrigin, const MbDirection &initDir, bool l=false) |
Initialize by a point and direction vector. | |
void | Init (const MbCartPoint &initOrigin, double angle, bool l=false) |
Initialize by a point and an angle. | |
void | Init (const MbCartPoint &, const MbVector &, const MbVector &) |
Initialize by a point and two vectors. | |
const MbCartPoint & | GetOrigin () const |
Get the origin of local coordinate system. | |
const MbVector & | GetAxisX () const |
Get the X-axis. | |
const MbVector & | GetAxisY () const |
Get the Y-axis. | |
void | GetOrigin (MbCartPoint &pc) const |
Get the origin of local coordinate system. | |
void | GetPointAndDerivesFrom (MbCartPoint &point, MbVector &firstDer, MbVector &secondDer, MbVector &thirdDer, MbeLocalSystemType type=ls_CartesSystem) const |
Transform a point and the first three derivatives from a local coordinate system to the global coordinate system. | |
MbCartPoint & | SetOrigin () |
Get the origin of local coordinate system. | |
MbVector & | SetAxisX () |
Get the X-axis. | |
MbVector & | SetAxisY () |
Get the Y-axis. | |
void | SetOrigin (const MbCartPoint &p) |
Set the origin of local coordinate system. | |
void | SetAxisX (const MbDirection &v) |
Set the X-axis. | |
void | SetAxisY (const MbDirection &v) |
Set the Y-axis. | |
void | SetAxisX (const MbVector &v) |
Set the X-axis. | |
void | SetAxisY (const MbVector &v) |
Set the Y-axis. | |
void | GetMatrixInto (MbMatrix &m) const |
Get the matrix of transformation to the local coordinate system: r=R*into (inverse matrix). | |
void | GetMatrixFrom (MbMatrix &m) const |
Get the matrix of transformation from the local coordinate system: R=r*from (direct matrix). | |
void | Move (const MbVector &) |
Translate along a vector. | |
void | Move (double dx, double dy) |
Translate by given increments. | |
void | Rotate (const MbCartPoint &pnt, double angle) |
Rotate at angle around a point. | |
void | Rotate (const MbCartPoint &pnt, const MbDirection &angle) |
Rotate around a point at the angle given by direction vector. | |
void | Transform (const MbMatrix &matr) |
Transform according to the matrix. | |
void | Calculate (const MbCartPoint &from, const MbCartPoint &to) |
Calculate the coordinate system by the start point and the end point. | |
void | Reset () |
Recalculate the coordinate system by changed internal data. More... | |
bool | IsSame (const MbPlacement &other, double accuracy) const |
Determine whether an object is equal? | |
void | InvertAxisX () |
Invert the 0X-axis. | |
void | InvertAxisY () |
Invert the 0Y-axis. | |
bool | operator== (const MbPlacement &) const |
Check for equality. | |
bool | operator!= (const MbPlacement &) const |
Check for inequality. | |
void | operator= (const MbPlacement &) |
Assign another coordinate system. | |
MbPlacement | operator* (const MbPlacement &p) const |
Multiply by a local coordinate system: P = this * p (as of matrix multiplication). | |
void | TransformInto (MbCartPoint &) const |
Transform point from the global coordinate system to a local coordinate system. | |
void | TransformFrom (MbCartPoint &) const |
Transform point from a local coordinate system to the global coordinate system. | |
void | TransformInto (MbVector &) const |
Transform a vector from the global coordinate system to a local coordinate system. | |
void | TransformFrom (MbVector &) const |
Transform a vector from a local coordinate system to the global coordinate system. | |
void | Normalize () |
Normalize. | |
bool | IsSingle () const |
Property of coincidence with global coordinate system. | |
bool | IsTranslation () const |
Check if a coordinate system is translated relative to the global coordinate system. | |
bool | IsRotation () const |
Check if the coordinate system is rotated relative to the global coordinate system. | |
bool | IsLeft () const |
Get attribute of left placement. | |
bool | IsOrt () const |
Check if a coordinate system is orthogonal, but not normalized. | |
bool | IsOrthogonal () const |
Check orthogonality of a coordinate system. | |
bool | IsAffine () const |
Check if a coordinate system is affine (otherwise it is orthonormalized). | |
bool | IsNormal () const |
Check if a coordinate system is orthonormalized. | |
bool | IsUnSet () const |
Check whether bit flags are not set. | |
bool | CheckLeft () |
Calculate and return attribute of left placement. | |
bool | IsCardinalPoint (double eps=Math::AngleEps) const |
Check orthogonality. | |
bool | IsCardinalStrict (double eps) const |
Check if parallel to 0X-axis or 0Y-axis. | |
bool | IsTranslationStandard () const |
Check if axes of coordinate system are coincident to a standard one (right orthonormalized coordinate system). | |
bool | IsCircular () const |
Check if a coordinate system is orthogonal with axes X and Y of equal length (circle moves to circle). | |
bool | IsCircular (double &lxy) const |
Check if a coordinate system is orthogonal with axes X and Y of equal length (circle moves to circle). | |
bool | IsIsotropic () const |
Check if a coordinate system is orthogonal with axes X and Y of equal length (circle moves to circle). | |
bool | IsIsotropic (double &lxy) const |
Check if a coordinate system is orthogonal with axes X and Y of equal length (circle moves to circle). | |
void | GetProperties (MbProperties &properties) |
Get properties of the object. | |
void | SetProperties (const MbProperties &properties) |
Set properties of the object. | |
Local coordinate system in two dimensional space.
Local coordinate system in two dimensional space.
Local coordinate system is described by the initial point and two non-parallel vectors. In most cases the system of coordinates is right, and vectors of system are orthonormalized. A coordinate system can become left and not orthonormalized via transformations. Local coordinate system is Cartesian, Point in the Cartesian coordinate system is defined by two coordinates x, y.
void MbPlacement::Reset | ( | ) |
Recalculate the coordinate system by changed internal data.
Scale the local coordinate system.