22#include <gz/math/Pose3.hh>
23#include <gz/utils/ImplPtr.hh>
27#include "sdf/config.hh"
33 inline namespace SDF_VERSION_NAMESPACE {
38 struct FrameAttachedToGraph;
39 struct PoseRelativeToGraph;
40 template <
typename T>
class ScopedGraph;
101 public:
const std::string &
Name()
const;
106 public:
void SetName(
const std::string &_name);
167 public:
const gz::math::Pose3d &
RawPose()
const;
277 private:
void SetFrameAttachedToGraph(
283 private:
void SetPoseRelativeToGraph(
293 GZ_UTILS_IMPL_PTR(dataPtr)
Parameters related to the axis of rotation for rotational joints, and the axis of translation for pri...
Definition JointAxis.hh:122
void SetRawPose(const gz::math::Pose3d &_pose)
Set the pose of the joint.
bool AddSensor(const Sensor &_sensor)
Add a sensors to the joint.
const std::string & Name() const
Get the name of the joint.
double ScrewThreadPitch() const
Get the displacement along the joint axis for each complete revolution around the joint axis (only va...
const Sensor * SensorByName(const std::string &_name) const
Get a sensor based on a name.
void SetScrewThreadPitch(double _threadPitch)
Set the thread pitch (only valid for screw joints).
const Sensor * SensorByIndex(const uint64_t _index) const
Get a sensor based on an index.
sdf::ElementPtr ToElement() const
Create and return an SDF element filled with data from this joint.
double ThreadPitch() const
Get the thread pitch in gazebo-classic format (only valid for screw joints).
Errors ResolveChildLink(std::string &_link) const
Resolve the name of the child link from the FrameAttachedToGraph.
const std::string & PoseRelativeTo() const
Get the name of the coordinate frame relative to which this object's pose is expressed.
const std::string & ChildName() const
Get the name of this joint's child frame.
void SetThreadPitch(double _threadPitch)
Set the thread pitch in gazebo-classic format (only valid for screw joints).
void SetChildName(const std::string &_name)
Set the name of the child frame.
void SetPoseRelativeTo(const std::string &_frame)
Set the name of the coordinate frame relative to which this object's pose is expressed.
void ClearSensors()
Remove all sensors.
sdf::SemanticPose SemanticPose() const
Get SemanticPose object of this object to aid in resolving poses.
Errors ResolveParentLink(std::string &_link) const
Resolve the name of the parent link from the FrameAttachedToGraph.
sdf::ElementPtr Element() const
Get a pointer to the SDF element that was used during load.
void SetType(const JointType _jointType)
Set the joint type.
Sensor * SensorByIndex(uint64_t _index)
Get a mutable sensor based on an index.
bool SensorNameExists(const std::string &_name) const
Get whether a sensor name exists.
void SetName(const std::string &_name)
Set the name of the joint.
void SetParentName(const std::string &_name)
Set the name of the parent frame.
JointType Type() const
Get the joint type.
const std::string & ParentName() const
Get the name of this joint's parent frame.
Joint()
Default constructor.
void SetAxis(const unsigned int _index, const JointAxis &_axis)
Set a joint axis.
const JointAxis * Axis(const unsigned int _index=0) const
Get a joint axis.
const gz::math::Pose3d & RawPose() const
Get the pose of the joint.
uint64_t SensorCount() const
Get the number of sensors.
Sensor * SensorByName(const std::string &_name)
Get a mutable sensor based on a name.
Errors Load(ElementPtr _sdf)
Load the joint based on a element pointer.
Definition Collision.hh:44
SemanticPose is a data structure that can be used by different DOM objects to resolve poses on a Pose...
Definition SemanticPose.hh:55
Information about an SDF sensor.
Definition Sensor.hh:141
JointType
The set of joint types.
Definition Joint.hh:47
@ REVOLUTE
A hinge joint that rotates on a single axis with a fixed range of motion.
@ BALL
A ball and socket joint.
@ SCREW
A single degree of freedom joint with coupled sliding and rotational motion.
@ REVOLUTE2
Same as two revolute joints connected in series.
@ GEARBOX
Geared revolute joint.
@ PRISMATIC
A sliding joint that slides along an axis with a limited range specified by upper and lower limits.
@ UNIVERSAL
Similar to a ball joint, but constrains one degree of freedom.
@ CONTINUOUS
A hinge joint that rotates on a single axis with a continuous range of motion.
@ FIXED
A joint with zero degrees of freedom that rigidly connects two links.
std::vector< Error > Errors
A vector of Error.
Definition Types.hh:81
std::shared_ptr< Element > ElementPtr
Definition Element.hh:55
namespace for Simulation Description Format parser
Definition Actor.hh:35
#define SDFORMAT_VISIBLE
Use to represent "symbol visible" if supported.
Definition system_util.hh:25