#include <hpp/fcl/shape/geometric_shapes.h>
Public Member Functions | |
Convex (bool ownStorage, Vec3f *points_, int num_points_, PolygonT *polygons_, int num_polygons_) | |
Constructing a convex, providing normal and offset of each polytype surface, and the points and shape topology information. More... | |
Convex (const Convex &other) | |
Copy constructor Only the list of neighbors is copied. More... | |
~Convex () | |
Matrix3f | computeMomentofInertia () const |
based on http://number-none.com/blow/inertia/bb_inertia.doc More... | |
Vec3f | computeCOM () const |
compute center of mass More... | |
FCL_REAL | computeVolume () const |
compute the volume More... | |
![]() | |
virtual | ~ConvexBase () |
void | computeLocalAABB () |
Compute AABB. More... | |
NODE_TYPE | getNodeType () const |
Get node type: a conex polytope. More... | |
![]() | |
ShapeBase () | |
virtual | ~ShapeBase () |
OBJECT_TYPE | getObjectType () const |
Get object type: a geometric shape. More... | |
![]() | |
CollisionGeometry () | |
virtual | ~CollisionGeometry () |
void * | getUserData () const |
get user data in geometry More... | |
void | setUserData (void *data) |
set user data in geometry More... | |
bool | isOccupied () const |
whether the object is completely occupied More... | |
bool | isFree () const |
whether the object is completely free More... | |
bool | isUncertain () const |
whether the object has some uncertainty More... | |
virtual Matrix3f | computeMomentofInertiaRelatedToCOM () const |
compute the inertia matrix, related to the com More... | |
Public Attributes | |
PolygonT * | polygons |
An array of PolygonT object. More... | |
int | num_polygons |
![]() | |
Vec3f * | points |
An array of the points of the polygon. More... | |
int | num_points |
Neighbors * | neighbors |
Neighbors of each vertex. More... | |
Vec3f | center |
center of the convex polytope, this is used for collision: center is guaranteed in the internal of the polytope (as it is convex) More... | |
![]() | |
Vec3f | aabb_center |
AABB center in local coordinate. More... | |
FCL_REAL | aabb_radius |
AABB radius. More... | |
AABB | aabb_local |
AABB in local coordinate, used for tight AABB when only translation transform. More... | |
void * | user_data |
pointer to user defined data specific to this object More... | |
FCL_REAL | cost_density |
collision cost for unit volume More... | |
FCL_REAL | threshold_occupied |
threshold for occupied ( >= is occupied) More... | |
FCL_REAL | threshold_free |
threshold for free (<= is free) More... | |
Protected Member Functions | |
void | fillNeighbors () |
![]() | |
ConvexBase (bool ownStorage, Vec3f *points_, int num_points_) | |
Constructing a convex, providing normal and offset of each polytype surface, and the points and shape topology information. More... | |
ConvexBase (const ConvexBase &other) | |
Copy constructor Only the list of neighbors is copied. More... | |
Additional Inherited Members | |
![]() | |
unsigned int * | nneighbors_ |
bool | own_storage_ |
Convex polytope.
PolygonT | the polygon class. It must have method size() and operator[](int i) |
hpp::fcl::Convex< PolygonT >::Convex | ( | bool | ownStorage, |
Vec3f * | points_, | ||
int | num_points_, | ||
PolygonT * | polygons_, | ||
int | num_polygons_ | ||
) |
Constructing a convex, providing normal and offset of each polytype surface, and the points and shape topology information.
ownStorage | whether this class owns the pointers of points and polygons. If owned, they are deleted upon destruction. |
points_ | list of 3D points |
num_points_ | number of 3D points |
polygons_ | An array of PolygonT object. PolygonT should contains a list of vertices for each polygon, in counter clockwise order. |
num_polygons_ | the number of polygons. |
References hpp::fcl::Convex< PolygonT >::fillNeighbors().
hpp::fcl::Convex< PolygonT >::Convex | ( | const Convex< PolygonT > & | other | ) |
Copy constructor Only the list of neighbors is copied.
References hpp::fcl::Convex< PolygonT >::num_polygons, hpp::fcl::ConvexBase::own_storage_, and hpp::fcl::Convex< PolygonT >::polygons.
hpp::fcl::Convex< PolygonT >::~Convex | ( | ) |
References hpp::fcl::ConvexBase::own_storage_, and hpp::fcl::Convex< PolygonT >::polygons.
|
virtual |
compute center of mass
Reimplemented from hpp::fcl::CollisionGeometry.
References hpp::fcl::Convex< PolygonT >::num_polygons, hpp::fcl::ConvexBase::points, and hpp::fcl::Convex< PolygonT >::polygons.
|
virtual |
based on http://number-none.com/blow/inertia/bb_inertia.doc
Reimplemented from hpp::fcl::CollisionGeometry.
References hpp::fcl::Convex< PolygonT >::num_polygons, hpp::fcl::ConvexBase::points, and hpp::fcl::Convex< PolygonT >::polygons.
|
virtual |
compute the volume
Reimplemented from hpp::fcl::CollisionGeometry.
References hpp::fcl::Convex< PolygonT >::num_polygons, hpp::fcl::ConvexBase::points, and hpp::fcl::Convex< PolygonT >::polygons.
|
protected |
References hpp::fcl::ConvexBase::Neighbors::count_, hpp::fcl::ConvexBase::Neighbors::n_, hpp::fcl::ConvexBase::neighbors, hpp::fcl::ConvexBase::nneighbors_, hpp::fcl::ConvexBase::num_points, hpp::fcl::Convex< PolygonT >::num_polygons, and hpp::fcl::Convex< PolygonT >::polygons.
Referenced by hpp::fcl::Convex< PolygonT >::Convex().
int hpp::fcl::Convex< PolygonT >::num_polygons |
PolygonT* hpp::fcl::Convex< PolygonT >::polygons |
An array of PolygonT object.
PolygonT should contains a list of vertices for each polygon, in counter clockwise order.
Referenced by hpp::fcl::Convex< PolygonT >::computeCOM(), hpp::fcl::Convex< PolygonT >::computeMomentofInertia(), hpp::fcl::Convex< PolygonT >::computeVolume(), hpp::fcl::Convex< PolygonT >::Convex(), hpp::fcl::Convex< PolygonT >::fillNeighbors(), and hpp::fcl::Convex< PolygonT >::~Convex().