The ProximityStrategy interface is a clean interface for defining methods that are common for different proximity strategy classes. Specifically adding of geometric models and relating them to frames.
More...
#include <ProximityStrategy.hpp>
Inherited by CollisionStrategy [virtual]
, CollisionToleranceStrategy [virtual]
, DistanceMultiStrategy [virtual]
, DistanceStrategy [virtual]
, and ContactStrategy.
|
size_t | _threads |
| the number of threads the strategy may use
|
|
The ProximityStrategy interface is a clean interface for defining methods that are common for different proximity strategy classes. Specifically adding of geometric models and relating them to frames.
◆ addGeometry() [1/2]
adds geometry to a specific proximity model. The proximity strategy copies all data of the geometry.
- Parameters
-
model | [in] the proximity model to add data to |
geom | [in] the geometry that is to be added |
Implemented in ContactStrategy, ODEContactStrategy, BtContactStrategy, ContactStrategyGeometry< A, B >, ContactStrategyDMS< T >, BallBallStrategy, ProximityStrategyYaobi, ProximityStrategyPQP, ProximityStrategyFCL, ProximityStrategyBullet, and ProximityStrategyRW.
◆ addGeometry() [2/2]
◆ addModel() [1/3]
Adds a Proximity model to a frame where the geometry is copied in the underlying proximity strategy.
The Proximity model is constructed from the list of faces
- Parameters
-
frame | [in] the frame to which the Proximity model should associate |
faces | [in] list of faces from which to construct the Proximity model |
- Returns
- true if a Proximity model was succesfully created and linked with the frame; false otherwise.
◆ addModel() [2/3]
Adds a Proximity model to a frame.
The Proximity model is constructed from the list of faces
- Parameters
-
frame | [in] the frame to which the Proximity model should associate |
faces | [in] list of faces from which to construct the Proximity model |
forceCopy | [in] force the strategy to copy the geometry data, if false the strategy may choose to store the geometry reference or not. |
- Returns
- true if a Proximity model was succesfully created and linked with the frame; false otherwise.
◆ addModel() [3/3]
Adds a Proximity model of a frame to this strategy.
The Proximity model is the one specified in the frames property
- Parameters
-
object | [in] the frame on which the Proximity model is to be created. |
- Returns
- true if a Proximity model was succesfully created and linked with the frame; false otherwise.
◆ destroyModel()
deallocates the memory used for model
- Parameters
-
Implemented in ContactStrategy, ODEContactStrategy, BtContactStrategy, ContactStrategyGeometry< A, B >, ContactStrategyDMS< T >, BallBallStrategy, ProximityStrategyYaobi, ProximityStrategyPQP, ProximityStrategyFCL, ProximityStrategyBullet, and ProximityStrategyRW.
◆ getGeometries()
◆ getGeometryIDs()
virtual std::vector<std::string> getGeometryIDs |
( |
ProximityModel * |
model | ) |
|
|
pure virtual |
the list of all geometry ids that are associated to the proximity model model is returned
- Parameters
-
model | [in] the model containing the geometries |
- Returns
- all geometry ids associated to the proximity model
Implemented in ContactStrategy, ODEContactStrategy, BtContactStrategy, ContactStrategyGeometry< A, B >, ContactStrategyDMS< T >, BallBallStrategy, ProximityStrategyYaobi, ProximityStrategyPQP, ProximityStrategyFCL, ProximityStrategyBullet, and ProximityStrategyRW.
◆ getModel()
get the proximitymodel associated to frame. If no model has been associated to frame then NULL is returned.
- Parameters
-
frame | [in] frame for which an proximitymodel is associated |
◆ hasModel()
Tells whether the frame has a proximity model in the strategy.
To have a proximity model does not means that it is loaded. If a GeoID string from which a model can be loaded it returns true as well
- Parameters
-
frame | [in] the frame to check for1.0/ |
- Returns
- true if a model exists or can be created
◆ useThreads()
void useThreads |
( |
int |
threads | ) |
|
setNumber of threads the strategy may use
- Parameters
-
threads | [in] number of threads. if Threads <= 0 then maximum threads available |
- Note
- this does not enforce the use of threads in the algorithms but mearly allows for the use.
The documentation for this class was generated from the following file: