3 #include <rigidmotion/RigidMotion.h>
6 #include <boost/serialization/void_cast.hpp>
7 #include <boost/serialization/base_object.hpp>
8 #include <boost/serialization/deque.hpp>
13 using std::shared_ptr;
14 using std::make_shared;
30 friend class boost::serialization::access;
37 template <
typename Archive>
38 void serialize(Archive &ar,
const unsigned int version){
39 boost::serialization::void_cast_register<DynMotion, RigidMotion>();
40 ar &boost::serialization::base_object<RigidMotion>(*
this);
62 bool selfMode =
false;
77 bool normalMode =
false;
111 virtual bool checkModifiesNormal()
const;
146 virtual DynMotion makeNormalCounterpart()
const;
153 {
return make_shared<DynMotion>(makeNormalCounterpart());}
171 inline void setSelfMode(
bool const selfMode) {this->selfMode = selfMode;}
187 {this->normalMode = normalMode;}
Class which wraps the RigidMotion class to implement extra features such as the self mode control mec...
Definition: DynMotion.h:26
DynMotion(colvec const &C, arma::mat const &A)
Dynamic motion construction from given translation column vector and fixed origin transformation matr...
Definition: DynMotion.h:100
bool isNormalMode() const
Check if normal mode is enabled for the dynamic motion (true) or not (false)
Definition: DynMotion.h:179
virtual shared_ptr< DynMotion > makeNormalCounterpartPtr() const
Like makeNormalCounterpart method but returning a shared pointer instead of the raw object.
Definition: DynMotion.h:152
void setNormalMode(bool const normalMode)
Enable or disable normal mode.
Definition: DynMotion.h:186
bool isSelfMode() const
Check if self mode is enabled for the dynamic motion (true) or not (false)
Definition: DynMotion.h:164
void setSelfMode(bool const selfMode)
Enable or disable self mode.
Definition: DynMotion.h:171
void serialize(Archive &ar, const unsigned int version)
Serialize a dynamic motion to a stream of bytes.
Definition: DynMotion.h:38
DynMotion(RigidMotion const &rm, bool selfMode=false)
Dynamic motion construction from a rigid motion as basis.
Definition: DynMotion.h:89
Interface that must be implemented by any class which represents a specific rigid motions.
Definition: RigidMotion.h:49