Mundy: Multibody Nonlocal Dynamics Version of the Day
Loading...
Searching...
No Matches
mundy::Spherocylinder< Scalar, PointType, QuaternionType > Class Template Reference

#include <Spherocylinder.hpp>

Public Member Functions

Constructors and destructor
constexpr Spherocylinder ()
 Default constructor for owning Spherocylinders. Default initializes the center and sets the radius to an invalid value of -1.
constexpr Spherocylinder (const point_t &center, const orientation_t &orientation, const value_type &radius, const value_type &length)
 Constructor to initialize the center and radius.
template<ValidPointType OtherPointType, ValidQuaternionType OtherQuaternionType>
constexpr Spherocylinder (const OtherPointType &center, const OtherQuaternionType &orientation, const value_type &radius, const value_type &length)
 Constructor to initialize the center and radius.
constexpr ~Spherocylinder ()=default
 Destructor.
constexpr Spherocylinder (const Spherocylinder< value_type, point_t, orientation_t > &other)
 Deep copy constructor.
template<typename OtherSpherocylinderType>
constexpr Spherocylinder (const OtherSpherocylinderType &other)
 Deep copy constructor with different spherocylinder type.
constexpr Spherocylinder (Spherocylinder< value_type, point_t, orientation_t > &&other)
 Deep move constructor.
template<typename OtherSpherocylinderType>
constexpr Spherocylinder (OtherSpherocylinderType &&other)
 Deep move constructor.
Operators
constexpr Spherocylinder< value_type, point_t, orientation_t > & operator= (const Spherocylinder< value_type, point_t, orientation_t > &other)
 Copy assignment operator.
template<typename OtherSpherocylinderType>
constexpr Spherocylinder< value_type, point_t, orientation_t > & operator= (const OtherSpherocylinderType &other)
 Copy assignment operator.
constexpr Spherocylinder< value_type, point_t, orientation_t > & operator= (Spherocylinder< value_type, point_t, orientation_t > &&other)
 Move assignment operator.
template<typename OtherSpherocylinderType>
constexpr Spherocylinder< value_type, point_t, orientation_t > & operator= (OtherSpherocylinderType &&other)
 Move assignment operator.
Accessors
constexpr const point_tcenter () const
 Accessor for the center.
constexpr point_tcenter ()
 Accessor for the center.
constexpr const orientation_torientation () const
 Accessor for the orientation.
constexpr orientation_torientation ()
 Accessor for the orientation.
constexpr const value_typeradius () const
 Accessor for the radius.
constexpr value_typeradius ()
 Accessor for the radius.
constexpr const value_typelength () const
 Accessor for the length.
constexpr value_typelength ()
 Accessor for the length.

Type aliases

using value_type = Scalar
 Our scalar type.
using point_t = PointType
 Our point type.
using orientation_t = QuaternionType
 Our orientation type.
static constexpr bool is_finite = true

Setters

template<ValidPointType OtherPointType>
constexpr void set_center (const OtherPointType &center)
 Set the center.
constexpr void set_center (const value_type &x, const value_type &y, const value_type &z)
 Set the center.
constexpr void set_orientation (const orientation_t &orientation)
 Set the orientation.
constexpr void set_orientation (const value_type &qw, const value_type &qx, const value_type &qy, const value_type &qz)
 Set the orientation.
constexpr void set_radius (const value_type &radius)
 Set the radius.
constexpr void set_length (const value_type &length)
 Set the length.