RobWorkProject  23.9.11-
Public Member Functions | List of all members
OBRManifold Class Reference

Contact manifold based on Oriented Bounding Rectangle, so in 2D. More...

#include <OBRManifold.hpp>

Public Member Functions

 OBRManifold (double thres=0.03, double sepThres=0.01)
 Constructor. More...
 
virtual ~OBRManifold ()
 Destructor.
 
bool addPoint (ContactPoint &p)
 adds and updates the manifold with a new point More...
 
ContactPointgetDeepestPoint ()
 Get the deepest point in manifold. More...
 
void update (const rw::math::Transform3D<> &aT, const rw::math::Transform3D<> &bT)
 Update the position of the contacts. More...
 
int getNrOfContacts ()
 Get number of contacts in manifold. More...
 
bool inManifold (ContactPoint &p)
 Check if a point lies within manifold. More...
 
void fit (ContactPoint &p)
 fits a new manifold to the list of contact points More...
 
rw::math::Vector3D getNormal ()
 Get the normal. More...
 
ContactPointgetContact (int i)
 Get contact. More...
 
rw::math::Transform3D getTransform ()
 Get the transform. More...
 
rw::math::Vector3D getHalfLengths ()
 Get half lengths of the manifold. More...
 

Detailed Description

Contact manifold based on Oriented Bounding Rectangle, so in 2D.

Constructor & Destructor Documentation

◆ OBRManifold()

OBRManifold ( double  thres = 0.03,
double  sepThres = 0.01 
)
inline

Constructor.

Parameters
thres[in] (optional) the angle threshold in radians. Threshold of angle between contact normals. Default is 0.03 radians.
sepThres[in] (optional) the max seperating distance in meter between contacting points. Default is 0.01 meter.

Member Function Documentation

◆ addPoint()

bool addPoint ( ContactPoint p)

adds and updates the manifold with a new point

Parameters
pthe new point to add
Returns
True if point is a part of the manifold, else false

◆ fit()

void fit ( ContactPoint p)

fits a new manifold to the list of contact points

Parameters
p

◆ getContact()

ContactPoint& getContact ( int  i)
inline

Get contact.

Parameters
i[in] contact index.
Returns
the contact at index i.

◆ getDeepestPoint()

ContactPoint& getDeepestPoint ( )
inline

Get the deepest point in manifold.

Returns
the deepest point.

◆ getHalfLengths()

rw::math::Vector3D getHalfLengths ( )
inline

Get half lengths of the manifold.

Returns
half lengths.

◆ getNormal()

rw::math::Vector3D getNormal ( )
inline

Get the normal.

Returns
the normal.

◆ getNrOfContacts()

int getNrOfContacts ( )
inline

Get number of contacts in manifold.

Returns
the number of contacts.

◆ getTransform()

rw::math::Transform3D getTransform ( void  )
inline

Get the transform.

Returns
the transform.

◆ inManifold()

bool inManifold ( ContactPoint p)
inline

Check if a point lies within manifold.

Parameters
p[in] point to check.
Returns
true if inside manifold, false otherwise.

◆ update()

void update ( const rw::math::Transform3D<> &  aT,
const rw::math::Transform3D<> &  bT 
)
inline

Update the position of the contacts.

Parameters
aT[in] transform of the first object.
bT[in] transform of the second object.

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