chrono::geometry::ChGeometry Class Referenceabstract

Description

Base class for geometric objects used for collisions and visualization.

#include <ChGeometry.h>

Inheritance diagram for chrono::geometry::ChGeometry:

Public Types

enum  Type {
  NONE, SPHERE, ELLIPSOID, BOX,
  CYLINDER, TRIANGLE, CAPSULE, CONE,
  LINE, LINE_ARC, LINE_BEZIER, LINE_CAM,
  LINE_PATH, LINE_POLY, LINE_SEGMENT, ROUNDED_BOX,
  ROUNDED_CYLINDER, TRIANGLEMESH, TRIANGLEMESH_CONNECTED, TRIANGLEMESH_SOUP
}
 Enumeration of geometric object types.
 

Public Member Functions

 ChGeometry (const ChGeometry &source)
 
virtual ChGeometryClone () const =0
 "Virtual" copy constructor.
 
virtual Type GetClassType () const
 Get the class type as an enum.
 
virtual ChAABB GetBoundingBox () const
 Compute bounding box along the directions of the shape definition frame. More...
 
void InflateBoundingBox (ChAABB &bbox) const
 Enlarge the given existing bounding box with the bounding box of this object.
 
virtual double GetBoundingSphereRadius () const
 Returns the radius of a bounding sphere for this geometry. More...
 
virtual ChVector Baricenter () const
 Compute center of mass.
 
virtual int GetManifoldDimension () const
 Returns the dimension of the geometry (0=point, 1=line, 2=surface, 3=solid)
 
virtual void Update ()
 Generic update of internal data.
 
virtual void ArchiveOut (ChArchiveOut &marchive)
 Method to allow serialization of transient data to archives.
 
virtual void ArchiveIn (ChArchiveIn &marchive)
 Method to allow de serialization of transient data from archives.
 

Member Function Documentation

◆ GetBoundingBox()

ChAABB chrono::geometry::ChGeometry::GetBoundingBox ( ) const
virtual

◆ GetBoundingSphereRadius()

double chrono::geometry::ChGeometry::GetBoundingSphereRadius ( ) const
virtual

Returns the radius of a bounding sphere for this geometry.

The default implementation returns the radius of a sphere bounding the geometry bounding box, which is not always the tightest possible.

Reimplemented in chrono::geometry::ChEllipsoid, chrono::geometry::ChRoundedBox, chrono::geometry::ChSphere, chrono::geometry::ChBox, chrono::geometry::ChCapsule, chrono::geometry::ChCone, chrono::geometry::ChCylinder, and chrono::geometry::ChRoundedCylinder.


The documentation for this class was generated from the following files:
  • /builds/uwsbel/chrono/src/chrono/geometry/ChGeometry.h
  • /builds/uwsbel/chrono/src/chrono/geometry/ChGeometry.cpp