16 #ifndef SURGSIM_MATH_SPHERESHAPE_H 17 #define SURGSIM_MATH_SPHERESHAPE_H 48 virtual double getVolume()
const override;
60 virtual bool isValid()
const override;
77 #endif // SURGSIM_MATH_SPHERESHAPE_H virtual bool isValid() const override
Definition: SphereShape.cpp:67
SphereShape(double radius=0.0)
Constructor.
Definition: SphereShape.cpp:24
Definition: DriveElementFromInputBehavior.cpp:27
virtual int getType() override
Definition: SphereShape.cpp:29
SURGSIM_STATIC_REGISTRATION(BoxShape)
::SurgSim::Math::Vector3d Vector3d
Definition: Shape.h:62
double getRadius() const
Get the sphere radius.
Definition: SphereShape.cpp:34
virtual Matrix33d getSecondMomentOfVolume() const override
Get the second central moment of the volume, commonly used to calculate the moment of inertia matrix...
Definition: SphereShape.cpp:54
double m_radius
Sphere radius.
Definition: SphereShape.h:71
Sphere shape: sphere centered on (0 0 0), defined with radius.
Definition: SphereShape.h:30
SURGSIM_CLASSNAME(SurgSim::Math::SphereShape)
::SurgSim::Math::Matrix33d Matrix33d
Definition: Shape.h:63
virtual double getVolume() const override
Get the volume of the shape.
Definition: SphereShape.cpp:44
void setRadius(double radius)
Set the sphere radius.
Definition: SphereShape.cpp:39
virtual Vector3d getCenter() const override
Get the volumetric center of the shape.
Definition: SphereShape.cpp:49
Generic rigid shape class defining a shape.
Definition: Shape.h:59