7 #ifndef GRIPPER_EQUIPPED_ENTITY_H
8 #define GRIPPER_EQUIPPED_ENTITY_H
11 class CGripperEquippedEntity;
12 class CEmbodiedEntity;
15 #include <argos3/core/simulator/entity/entity.h>
16 #include <argos3/core/utility/math/vector3.h>
17 #include <argos3/core/utility/math/quaternion.h>
64 const std::string& str_id,
67 Real f_lock_threshold = 0.5f);
102 m_cOffset = c_offset;
111 m_cInitOffset = c_offset;
128 return m_cInitDirection;
136 m_cDirection = c_direction;
145 m_cInitDirection = c_direction;
170 return m_fLockThreshold;
188 return m_fLockState > m_fLockThreshold;
196 return (m_pcGrippedEntity != NULL);
211 m_pcGrippedEntity = &c_entity;
218 m_pcGrippedEntity = NULL;
243 Real m_fLockThreshold;
void ClearGrippedEntity()
Clears the reference to the embodied entity currently gripped by this gripper.
const CVector3 & GetInitDirection() const
Returns the initial facing direction of the gripper with respect to the local X-axis.
Real GetLockThreshold() const
Returns the lock threshold of the gripper.
void SetLockThreshold(Real f_lock_threshold)
Sets the lock threshold of the gripper.
virtual void Reset()
Resets the state of the entity to whatever it was after Init() or one of the standalone constructors ...
void SetDirection(const CVector3 &c_direction)
Sets the facing direction of the gripper with respect to the local X-axis.
float Real
Collects all ARGoS code.
virtual std::string GetTypeDescription() const
Returns a string label for this class.
bool IsGripping() const
Returns true if this gripper is gripping something.
void SetInitDirection(const CVector3 &c_direction)
Sets the initial facing direction of the gripper with respect to the local X-axis.
ticpp::Element TConfigurationNode
The ARGoS configuration XML node.
This entity is a link to a body in the physics engine.
bool IsLocked() const
Returns true if the gripper is locked.
CGripperEquippedEntity(CComposableEntity *pc_parent)
Class constructor.
void SetOffset(const CVector3 &c_offset)
Sets the offset of the gripper with respect to the reference point.
void SetInitOffset(const CVector3 &c_offset)
Sets the initial offset of the gripper with respect to the reference point.
Basic class for an entity that contains other entities.
const CVector3 & GetDirection() const
Returns the facing direction of the gripper with respect to the local X-axis.
void SetGrippedEntity(CEmbodiedEntity &c_entity)
Sets the embodied entity currently gripped by this gripper.
Real GetLockState() const
Returns the lock state of the gripper.
const CVector3 & GetInitOffset() const
Returns the initial offset of the gripper with respect to the reference point.
const CVector3 & GetOffset() const
Returns the offset of the gripper with respect to the reference point.
CEmbodiedEntity & GetGrippedEntity()
Returns the embodied entity currently gripped by this gripper.
void SetLockState(Real f_lock_state)
Sets the lock state of the gripper.
The namespace containing all the ARGoS related code.
virtual void Init(TConfigurationNode &t_tree)
Initializes the state of the entity from the XML configuration tree.
An entity that stores the state of a robot gripper.