CellModules
orientable.h
Go to the documentation of this file.
1#ifndef ORIENTABLE_H
2#define ORIENTABLE_H
4namespace MecaCell {
5class Orientable {
6 protected:
11
12 public:
13 /**********************************************
14 * CONSTRUCTOR
15 **********************************************/
17
18 /**********************************************
19 * GET & SET
20 **********************************************/
22 Vec getTorque() const { return torque; }
25 void setAngularVelocity(const Vec& v) { angularVelocity = v; }
26 void setTorque(const Vec& t) { torque = t; }
28
29 /**********************************************
30 * UPDATES
31 **********************************************/
32 void receiveTorque(const Vec& t) { torque += t; }
36};
37}
38#endif
void setTorque(const Vec &t)
Definition: orientable.h:26
Basis< Vec > orientation
Definition: orientable.h:9
void setOrientationRotation(const Rotation< Vec > &r)
Definition: orientable.h:27
void resetAngularVelocity()
Definition: orientable.h:35
void setAngularVelocity(const Vec &v)
Definition: orientable.h:25
Vec getAngularVelocity() const
Definition: orientable.h:21
Basis< Vec > getOrientation() const
Definition: orientable.h:23
void updateCurrentOrientation()
Definition: orientable.h:33
void receiveTorque(const Vec &t)
Definition: orientable.h:32
Rotation< Vec > getOrientationRotation() const
Definition: orientable.h:24
Rotation< Vec > orientationRotation
Definition: orientable.h:10
Vec getTorque() const
Definition: orientable.h:22
general purpose 3D vector/point class.
Definition: vector3D.h:20
static Vector3D zero()
constructs a zero vector
Definition: vector3D.h:170
this file contains various miscellanious utility functions & helpers *