Contents, API Reference, Interfaces, iCollisionContext, getConnectedRegionFor
Returns an index for the connected region at a given position.
This can be used to quickly determine the reachability between positions.
int32_t getConnectedRegionFor(const iShape* shape, const cPosition& p) const;
The agent shape for which connected region preprocess should be queried.
The position to test.
Requires that the collision context includes an obstacle set that is
'marked for preprocessing',
or that connected region preprocess has been generated against the mesh for the query agent shape.
See Obstacle Management for details about setting up preprocessed obstacle sets.
Return ValueAn index value for the connected region at the given position.
If there is a preprocessed obstacle set included in this context then this query will effectively forward the query on
to a call to iObstacleSet::getNumberOfConnectedRegions() for that obstacle set.
Otherwise the query will be forwarded on to base mesh connected region preprocess iMesh::getNumberOfConnectedRegions().
int getConnectedRegionFor(Shape shape, PathEngine.Position p);
int getConnectedRegionFor(Shape shape, Position p);