Biorbd Release_1.13.0
Loading...
Searching...
No Matches
Compound.h
1#ifndef BIORBD_MUSCLES_COMPOUND_H
2#define BIORBD_MUSCLES_COMPOUND_H
3
4#include "biorbdConfig.h"
5
6#include <memory>
7#include <vector>
8
9#include "Utils/Scalar.h"
10
11namespace BIORBD_NAMESPACE {
12namespace utils {
13class String;
14class Vector3d;
15} // namespace utils
16
17namespace rigidbody {
18class Joints;
21} // namespace rigidbody
22namespace internal_forces {
23class PathModifiers;
24
29class BIORBD_API Compound {
30 public:
34 Compound();
35
41
48 const utils::String& name,
49 const internal_forces::PathModifiers& pathModifiers);
54 Compound(const Compound& other);
55
60 Compound(const std::shared_ptr<Compound> other);
61
65 virtual ~Compound();
66
71 void DeepCopy(const Compound& other);
72
77 void setName(const utils::String& name);
78
83 const utils::String& name() const;
84
85 // Wrapping object
91
97
102 virtual const utils::Scalar& force();
103
104 protected:
105 std::shared_ptr<utils::String> m_name;
106 std::shared_ptr<internal_forces::PathModifiers>
108 std::shared_ptr<utils::Scalar> m_force;
109};
110
111} // namespace internal_forces
112} // namespace BIORBD_NAMESPACE
113
114#endif // BIORBD_MUSCLES_COMPOUND_H
const internal_forces::PathModifiers & pathModifier()
Return the path modifier.
Definition Compound.cpp:55
std::shared_ptr< utils::String > m_name
The name of the muscle.
Definition Compound.h:105
const utils::String & name() const
Return the name of the muscle.
Definition Compound.cpp:48
void setName(const utils::String &name)
Set the name of a muscle.
Definition Compound.cpp:50
void addPathObject(utils::Vector3d &wrap)
Add a path modifier object.
Definition Compound.cpp:59
void DeepCopy(const Compound &other)
Deep copy of a compound.
Definition Compound.cpp:41
std::shared_ptr< utils::Scalar > m_force
The last computed force.
Definition Compound.h:108
virtual const utils::Scalar & force()
Return the last computed muscle force norm.
Definition Compound.cpp:63
Compound()
Construct muscle compound.
Definition Compound.cpp:11
std::shared_ptr< internal_forces::PathModifiers > m_pathChanger
The set of path modifiers.
Definition Compound.h:107
Holder of all the path modifiers of a muscle.
This is the core of the musculoskeletal model in biorbd.
Definition Joints.h:48
Wrapper around the std::string class with augmented functionality.
Definition String.h:18
Wrapper around Eigen Vector3d and attach it to a parent.
Definition Vector3d.h:27