29 #ifndef _libPhysic_BodyInteraction_tpp_
30 #define _libPhysic_BodyInteraction_tpp_
61 GRANOO_ACCESS_REF_CONST_PTR(body1,
Body,
_body1);
65 GRANOO_ACCESS_REF_CONST_PTR(body2,
Body,
_body2);
80 template<
class Archive>
void serialize(Archive &,
const unsigned int);
95 template<
class Archive>
99 ar & boost::serialization::base_object<NodeInteraction>(*
this);
104 #include <boost/serialization/version.hpp>
110 namespace serialization
113 template<
class Archive>
122 template<
class Archive>
136 GRANOO_CLASS_DECLARE_TPL(Physic::BodyInteraction);
BOOST_CLASS_VERSION(GranOO3::Physic::BodyInteraction, 0) namespace boost
Definition: BodyInteraction.hpp:105
Definition: SetOf.hpp:346
Definition: Vector.hpp:75
a class that represents a body
Definition: Body.hpp:43
a class that represents a generic physical interaction between two bodies
Definition: BodyInteraction.hpp:44
std::map< std::string, Geom::Vector > _energy_balance_torque2
a map of label for computing energy balance (internal usage only)
Definition: BodyInteraction.hpp:91
std::map< std::string, Geom::Vector > _energy_balance_torque1
a map of label for computing energy balance (internal usage only)
Definition: BodyInteraction.hpp:90
Body * _body1
a pointer the first body
Definition: BodyInteraction.hpp:84
void swap(Body &from, Body &to)
swap one body
Definition: BodyInteraction.cpp:100
BodyInteraction & operator=(const BodyInteraction &)=delete
Geom::Vector _torque_on2
the current value of the applied torque on the body 2
Definition: BodyInteraction.hpp:87
void serialize(Archive &, const unsigned int)
complete serializing of the item in the *.gdd format
Definition: BodyInteraction.hpp:97
Geom::Vector & torque_on(const Body &b)
get the torque value applied on b
Definition: BodyInteraction.cpp:55
void add_label_torque(const std::string &label, const Geom::Vector &t1, const Geom::Vector &t2)
add a label for the torque
Definition: BodyInteraction.cpp:93
BodyInteraction(const BodyInteraction &frame)=delete
Body * _body2
a pointer the second body
Definition: BodyInteraction.hpp:85
virtual ~BodyInteraction()
destructor
Definition: BodyInteraction.cpp:50
void clear_torque()
set the torques to zero
Definition: BodyInteraction.cpp:87
Geom::Vector _torque_on1
the current value of the applied torque on the body 1
Definition: BodyInteraction.hpp:86
friend class boost::serialization::access
Definition: BodyInteraction.hpp:79
void apply_torque()
apply the current torque value
Definition: BodyInteraction.cpp:77
Definition: NodeInteraction.hpp:41
bool contact_interaction() const
Definition: NodeInteraction.cpp:57
Definition: Common.hpp:198
void save_construct_data(Archive &ar, const GranOO3::Core::Pair< type > *t, const unsigned int)
Definition: Pair.hpp:207
void load_construct_data(Archive &ar, GranOO3::Core::Pair< type > *t, const unsigned int)
Definition: Pair.hpp:217
x y t t *t x y t t t x y t t t x *y t *t t x *y t *t t x y t t t x y t t t t(t+t)") define_sfop3(16