Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow "drilling down" into nested model frames #381

Merged
merged 75 commits into from
Nov 18, 2020
Merged
Show file tree
Hide file tree
Changes from 73 commits
Commits
Show all changes
75 commits
Select commit Hold shift + click to select a range
05a9037
Expect nested_explicit_canonical_link.sdf is valid
scpeters Sep 2, 2020
0931e65
Support :: syntax in *NameExists and *ByName APIs
scpeters Aug 12, 2020
79fc3e6
Changelog and Migration guide
scpeters Sep 3, 2020
8b92f41
Ensure CanonicalLink pointer is valid
scpeters Sep 3, 2020
6659e83
Merge branch 'master' into explicit_nested_canonical
scpeters Sep 10, 2020
a07b42b
Add ScopedGraph header
azeey Sep 23, 2020
612a805
Frame attached to tests passing
azeey Sep 24, 2020
f74fc33
FrameSemantics_TEST passing
azeey Sep 24, 2020
041e1c2
Pass ChildScope with new scope name
azeey Sep 25, 2020
aaf0742
Merge branch 'explicit_nested_canonical' into drill_down
azeey Sep 29, 2020
b0bf73b
Add command line tool to generate graph
azeey Oct 1, 2020
3fe002b
Avoid using the RawPose of the DOM object when the object is a frame …
azeey Oct 1, 2020
dc5f941
Handle placement frames with new PoseRelativeTo construction scheme
azeey Oct 1, 2020
46ff7c0
Add __root__ scope
azeey Oct 1, 2020
5fd9abc
Revert changes in loadUniqueRepeated
azeey Oct 1, 2020
565dffb
Make ScopedGraph use pointer semantics
azeey Oct 1, 2020
4cefd79
Cleanup
azeey Oct 6, 2020
446a536
Remove `__root__` scope name
azeey Oct 7, 2020
023aea5
SemanticPose::Resolve and JointAxis::ResolveXyz to a SemanticPose obj…
azeey Oct 7, 2020
71e24bb
Add missing file
azeey Oct 8, 2020
f97e00c
Remove aliasing edges, there is no need for them. Also remove updateG…
azeey Oct 8, 2020
dd835a6
Refactor
azeey Oct 8, 2020
50edaec
Cleanup
azeey Oct 8, 2020
9b6c99e
Add Resolve function that takes DOM objects
azeey Oct 8, 2020
1cecc0c
Add test for placement attribute with nested link
azeey Oct 8, 2020
eb78dbc
Codecheck
azeey Oct 8, 2020
2cbe572
Fix macOS build error
azeey Oct 8, 2020
67da6d8
Add nested model pose relative_to test
azeey Oct 8, 2020
db47ba2
Add nested model frame attached_to test
azeey Oct 8, 2020
28e2c61
Add test for joints that reference entities in nested models
azeey Oct 8, 2020
b36c1d2
Add API documentation for ScopedGraph, refactor
azeey Oct 9, 2020
e50ae0b
Add test for placement_frame element that references nested frames
azeey Oct 9, 2020
d5551bc
Add test for empty models that contain a nested static model
azeey Oct 9, 2020
d51f340
Resolve SemanticPose objects relative to other SemanticPose objects
azeey Oct 10, 2020
4d86a91
Add missing file
azeey Oct 10, 2020
7d34a5e
Revert the SemanticPose::Resolve API that takes SemanticPose objects
azeey Oct 14, 2020
1168672
Remove addNestedModel
azeey Oct 14, 2020
2482b74
Add more documentation, cleanup
azeey Oct 14, 2020
c99545f
Validate __root__ vertices
azeey Oct 14, 2020
1c07494
Add more error cases in validate* functions
azeey Oct 14, 2020
a628e1e
Remove obsolete test
azeey Oct 14, 2020
6a7482c
Prevent users from referencing `__root__` in SDFormat XML.
azeey Oct 14, 2020
3956ee6
More expectations in LoadJointNestedParentChild
scpeters Oct 19, 2020
f4b4098
Address Reviewer feedback
azeey Oct 22, 2020
4e368f1
Add and update doxygen for SetFrameAttachedToGraph and SetPoseRelativ…
azeey Oct 22, 2020
9810c10
Add doxygen to new SemanticPose constructor
azeey Oct 22, 2020
ea08d4f
Remove unnecessary code
azeey Oct 22, 2020
cd08f38
Refactor code that handles PlacementFrame into a function
azeey Oct 23, 2020
b158998
Address reviewer feedback
azeey Oct 23, 2020
635b96e
Add failing test showing bug in checkFrameAttachedToNames
azeey Oct 23, 2020
76515da
Fix how frame attached_to names are checked for existence
azeey Oct 23, 2020
d552382
Add unit test for the output stream of sdf::Errors
azeey Oct 23, 2020
60a903d
Return void from Model::SetPoseRelativeToGraph
azeey Oct 27, 2020
9c297d0
Add test for world level nested references
azeey Oct 27, 2020
de319b9
Add test for ign graph command
azeey Oct 27, 2020
2a21634
Be more selective about checking for usage of __root__
azeey Oct 27, 2020
f814bb1
Address reviewer feedback
azeey Oct 28, 2020
f4def9c
Merge remote-tracking branch 'upstream/master' into drill_down
azeey Oct 28, 2020
eef24a0
Scoped -> scoped
azeey Oct 30, 2020
3c61c82
Address reviewer feedback
azeey Oct 30, 2020
f5390ee
Change scopeName to scopeContextName
azeey Oct 30, 2020
f3a234e
Add warning to the help message of ign sdf -g command
azeey Oct 30, 2020
b5a3a48
Remove extraneous error comments
azeey Oct 30, 2020
38bee6e
Address reviewer feedback
azeey Oct 30, 2020
c5b037a
Merge remote-tracking branch 'upstream/master' into drill_down
azeey Oct 30, 2020
da10cb4
Resolve additional merge conflicts
azeey Oct 30, 2020
b0d3185
Cleanup
azeey Oct 30, 2020
5c42e39
Address reviewer feedback
azeey Nov 3, 2020
5470e60
Merge branch 'master' into drill_down
azeey Nov 3, 2020
f544805
State that *Count functions only count immediate child elements
azeey Nov 5, 2020
661a502
Address reviewer feedback
azeey Nov 5, 2020
d06275b
Typo
azeey Nov 5, 2020
8b0665a
Revert documentation updates to Root::*ByName and World::*ByName func…
azeey Nov 6, 2020
6390633
Keep some of the changes from the previous commit
azeey Nov 11, 2020
0a8a7e0
Move construction of PoseRelativeToGraph and FrameAttachedToGraph to …
azeey Nov 18, 2020
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions Migration.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,10 @@ but with improved human-readability..

### Modifications

1. **sdf/Model.hh**: the following methods now accept nested names
that can begin with a sequence of nested model names separated
by `::` and may end with the name of an object of the specified type.
1. **sdf/Model.hh**: the following methods now accept nested names relative to
the model's scope that can begin with a sequence of nested model names
separated by `::` and may end with the name of an object of the specified
type.
+ const Frame \*FrameByName(const std::string &) const
+ const Joint \*JointByName(const std::string &) const
+ const Link \*LinkByName(const std::string &) const
Expand Down
9 changes: 5 additions & 4 deletions include/sdf/Collision.hh
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ namespace sdf
class Geometry;
class Surface;
struct PoseRelativeToGraph;
template <typename T> class ScopedGraph;

/// \brief A collision element descibes the collision properties associated
/// with a link. This can be different from the visual properties of a link.
Expand Down Expand Up @@ -141,12 +142,12 @@ namespace sdf
/// \param[in] _xmlParentName Name of xml parent object.
private: void SetXmlParentName(const std::string &_xmlParentName);

/// \brief Give a weak pointer to the PoseRelativeToGraph to be used
/// for resolving poses. This is private and is intended to be called by
/// \brief Give the scoped PoseRelativeToGraph to be used for resolving
/// poses. This is private and is intended to be called by
/// Link::SetPoseRelativeToGraph.
/// \param[in] _graph Weak pointer to PoseRelativeToGraph.
/// \param[in] _graph scoped PoseRelativeToGraph object.
private: void SetPoseRelativeToGraph(
std::weak_ptr<const PoseRelativeToGraph> _graph);
sdf::ScopedGraph<PoseRelativeToGraph> _graph);

/// \brief Allow Link::SetPoseRelativeToGraph to call SetXmlParentName
/// and SetPoseRelativeToGraph, but Link::SetPoseRelativeToGraph is
Expand Down
26 changes: 13 additions & 13 deletions include/sdf/Frame.hh
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ namespace sdf
class FramePrivate;
struct FrameAttachedToGraph;
struct PoseRelativeToGraph;
template <typename T> class ScopedGraph;

/// \brief A Frame element descibes the properties associated with an
/// explicit frame defined in a Model or World.
Expand Down Expand Up @@ -133,9 +134,8 @@ namespace sdf
public: sdf::ElementPtr Element() const;

/// \brief Resolve the attached-to body of this frame from the
/// FrameAttachedToGraph. If this is in a __model__ scope, it returns
/// the name of a link. In the world scope, it returns the name of a
/// model or the world.
/// FrameAttachedToGraph. Generally, it resolves to the name of a link, but
/// if it is in the world scope, it can resolve to "world".
/// \param[out] _body Name of body to which this frame is attached.
/// \return Errors.
public: Errors ResolveAttachedToBody(std::string &_body) const;
Expand All @@ -145,19 +145,19 @@ namespace sdf
/// \return SemanticPose object for this link.
public: sdf::SemanticPose SemanticPose() const;

/// \brief Give a weak pointer to the FrameAttachedToGraph to be used
/// for resolving attached bodies. This is private and is intended to
/// be called by Model::Load or World::Load.
/// \param[in] _graph Weak pointer to FrameAttachedToGraph.
/// \brief Give a scoped FrameAttachedToGraph to be used for resolving
/// attached bodies. This is private and is intended to be called by
/// Model::Load or World::Load.
/// \param[in] _graph scoped FrameAttachedToGraph object.
private: void SetFrameAttachedToGraph(
std::weak_ptr<const FrameAttachedToGraph> _graph);
sdf::ScopedGraph<FrameAttachedToGraph> _graph);

/// \brief Give a weak pointer to the PoseRelativeToGraph to be used
/// for resolving poses. This is private and is intended to be called by
/// Model::Load or World::Load.
/// \param[in] _graph Weak pointer to PoseRelativeToGraph.
/// \brief Give the scoped PoseRelativeToGraph to be used for resolving
/// poses. This is private and is intended to be called by Model::Load or
/// World::Load.
/// \param[in] _graph scoped PoseRelativeToGraph object.
private: void SetPoseRelativeToGraph(
std::weak_ptr<const PoseRelativeToGraph> _graph);
sdf::ScopedGraph<PoseRelativeToGraph> _graph);

/// \brief Allow Model::Load and World::Load to call SetPoseRelativeToGraph.
friend class Model;
Expand Down
20 changes: 10 additions & 10 deletions include/sdf/Joint.hh
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ namespace sdf
class JointPrivate;
struct FrameAttachedToGraph;
struct PoseRelativeToGraph;
template <typename T> class ScopedGraph;

/// \enum JointType
/// \brief The set of joint types. INVALID indicates that joint type has
Expand Down Expand Up @@ -221,19 +222,18 @@ namespace sdf
/// \return SemanticPose object for this link.
public: sdf::SemanticPose SemanticPose() const;

/// \brief Give a weak pointer to the FrameAttachedToGraph to be used
/// for resolving parent and child link names. This is private and is
/// intended to be called by Model::Load.
/// \param[in] _graph Weak pointer to FrameAttachedToGraph.
/// \brief Give the scoped FrameAttachedToGraph to be used for resolving
/// parent and child link names. This is private and is intended to be
/// called by Model::Load.
/// \param[in] _graph scoped FrameAttachedToGraph object.
private: void SetFrameAttachedToGraph(
std::weak_ptr<const FrameAttachedToGraph> _graph);
sdf::ScopedGraph<FrameAttachedToGraph> _graph);

/// \brief Give a weak pointer to the PoseRelativeToGraph to be used
/// for resolving poses. This is private and is intended to be called by
/// Model::Load.
/// \param[in] _graph Weak pointer to PoseRelativeToGraph.
/// \brief Give the scoped PoseRelativeToGraph to be used for resolving
/// poses. This is private and is intended to be called by Model::Load.
/// \param[in] _graph scoped PoseRelativeToGraph object.
private: void SetPoseRelativeToGraph(
std::weak_ptr<const PoseRelativeToGraph> _graph);
sdf::ScopedGraph<PoseRelativeToGraph> _graph);

/// \brief Allow Model::Load to call SetPoseRelativeToGraph.
friend class Model;
Expand Down
11 changes: 6 additions & 5 deletions include/sdf/JointAxis.hh
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ namespace sdf
// Forward declare private data class.
class JointAxisPrivate;
struct PoseRelativeToGraph;
template <typename T> class ScopedGraph;

/// \brief Parameters related to the axis of rotation for rotational joints,
/// and the axis of translation for prismatic joints.
Expand Down Expand Up @@ -269,12 +270,12 @@ namespace sdf
/// \param[in] _xmlParentName Name of xml parent object.
private: void SetXmlParentName(const std::string &_xmlParentName);

/// \brief Give a weak pointer to the PoseRelativeToGraph to be used
/// for resolving poses. This is private and is intended to be called
/// by Joint::SetPoseRelativeToGraph.
/// \param[in] _graph Weak pointer to PoseRelativeToGraph.
/// \brief Give the scoped PoseRelativeToGraph to be used for resolving
/// poses. This is private and is intended to be called by
/// Joint::SetPoseRelativeToGraph.
/// \param[in] _graph scoped PoseRelativeToGraph object.
private: void SetPoseRelativeToGraph(
std::weak_ptr<const PoseRelativeToGraph> _graph);
sdf::ScopedGraph<PoseRelativeToGraph> _graph);

/// \brief Allow Joint::SetPoseRelativeToGraph to propagate.
friend class Joint;
Expand Down
9 changes: 5 additions & 4 deletions include/sdf/Light.hh
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ namespace sdf
// Forward declare private data class.
class LightPrivate;
struct PoseRelativeToGraph;
template <typename T> class ScopedGraph;

/// \enum LightType
/// \brief The set of light types. INVALID indicates that light type has
Expand Down Expand Up @@ -273,12 +274,12 @@ namespace sdf
/// \param[in] _xmlParentName Name of xml parent object.
private: void SetXmlParentName(const std::string &_xmlParentName);

/// \brief Give a weak pointer to the PoseRelativeToGraph to be used
/// for resolving poses. This is private and is intended to be called by
/// \brief Give the scoped PoseRelativeToGraph to be used for resolving
/// poses. This is private and is intended to be called by
/// Link::SetPoseRelativeToGraph or World::Load.
/// \param[in] _graph Weak pointer to PoseRelativeToGraph.
/// \param[in] _graph scoped PoseRelativeToGraph object.
private: void SetPoseRelativeToGraph(
std::weak_ptr<const PoseRelativeToGraph> _graph);
sdf::ScopedGraph<PoseRelativeToGraph> _graph);

/// \brief Allow Link::SetPoseRelativeToGraph or World::Load to call
/// SetXmlParentName and SetPoseRelativeToGraph,
Expand Down
10 changes: 5 additions & 5 deletions include/sdf/Link.hh
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ namespace sdf
class Visual;
class LinkPrivate;
struct PoseRelativeToGraph;
template <typename T> class ScopedGraph;

class SDFORMAT_VISIBLE Link
{
Expand Down Expand Up @@ -225,12 +226,11 @@ namespace sdf
/// \return SemanticPose object for this link.
public: sdf::SemanticPose SemanticPose() const;

/// \brief Give a weak pointer to the PoseRelativeToGraph to be used
/// for resolving poses. This is private and is intended to be called by
/// Model::Load.
/// \param[in] _graph Weak pointer to PoseRelativeToGraph.
/// \brief Give the scoped PoseRelativeToGraph to be used for resolving
/// poses. This is private and is intended to be called by Model::Load.
/// \param[in] _graph scoped PoseRelativeToGraph object.
private: void SetPoseRelativeToGraph(
std::weak_ptr<const PoseRelativeToGraph> _graph);
sdf::ScopedGraph<PoseRelativeToGraph> _graph);

/// \brief Allow Model::Load to call SetPoseRelativeToGraph.
friend class Model;
Expand Down
55 changes: 39 additions & 16 deletions include/sdf/Model.hh
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,8 @@ namespace sdf
class Link;
class ModelPrivate;
struct PoseRelativeToGraph;
struct FrameAttachedToGraph;
template <typename T> class ScopedGraph;

class SDFORMAT_VISIBLE Model
{
Expand Down Expand Up @@ -132,11 +134,14 @@ namespace sdf
/// should be subject to wind.
public: void SetEnableWind(bool _enableWind);

/// \brief Get the number of links.
/// \brief Get the number of links that are immediate (not nested) children
/// of this Model object.
/// \remark LinkByName() can find links that are not immediate children of
/// this Model object.
/// \return Number of links contained in this Model object.
public: uint64_t LinkCount() const;

/// \brief Get a link based on an index.
/// \brief Get an immediate (not nested) child link based on an index.
/// \param[in] _index Index of the link. The index should be in the
/// range [0..LinkCount()).
/// \return Pointer to the link. Nullptr if the index does not exist.
Expand All @@ -157,11 +162,14 @@ namespace sdf
/// \return True if there exists a link with the given name.
public: bool LinkNameExists(const std::string &_name) const;

/// \brief Get the number of joints.
/// \brief Get the number of joints that are immediate (not nested) children
/// of this Model object.
/// \remark JointByName() can find joints that are not immediate children of
/// this Model object.
/// \return Number of joints contained in this Model object.
public: uint64_t JointCount() const;

/// \brief Get a joint based on an index.
/// \brief Get an immediate (not nested) child joint based on an index.
/// \param[in] _index Index of the joint. The index should be in the
/// range [0..JointCount()).
/// \return Pointer to the joint. Nullptr if the index does not exist.
Expand All @@ -170,7 +178,7 @@ namespace sdf

/// \brief Get whether a joint name exists.
/// \param[in] _name Name of the joint to check.
/// To check for a joint in a nested model, prefix the link name with
/// To check for a joint in a nested model, prefix the joint name with
/// the sequence of nested models containing this joint, delimited by "::".
/// \return True if there exists a joint with the given name.
public: bool JointNameExists(const std::string &_name) const;
Expand All @@ -184,11 +192,15 @@ namespace sdf
/// \sa bool JointNameExists(const std::string &_name) const
public: const Joint *JointByName(const std::string &_name) const;

/// \brief Get the number of explicit frames.
/// \brief Get the number of explicit frames that are immediate (not nested)
/// children of this Model object.
/// \remark FrameByName() can find explicit frames that are not immediate
/// children of this Model object.
/// \return Number of explicit frames contained in this Model object.
public: uint64_t FrameCount() const;

/// \brief Get an explicit frame based on an index.
/// \brief Get an immediate (not nested) child explicit frame based on an
/// index.
/// \param[in] _index Index of the explicit frame. The index should be in
/// the range [0..FrameCount()).
/// \return Pointer to the explicit frame. Nullptr if the index does not
Expand All @@ -211,11 +223,15 @@ namespace sdf
/// \return True if there exists an explicit frame with the given name.
public: bool FrameNameExists(const std::string &_name) const;

/// \brief Get the number of nested models.
/// \brief Get the number of nested models that are immediate (not
/// recursively nested) children of this Model object.
/// \remark ModelByName() can find nested models that are not immediate
/// children of this Model object.
/// \return Number of nested models contained in this Model object.
public: uint64_t ModelCount() const;

/// \brief Get a nested model based on an index.
/// \brief Get an immediate (not recursively nested) child model based on an
/// index.
/// \param[in] _index Index of the nested model. The index should be in the
/// range [0..ModelCount()).
/// \return Pointer to the model. Nullptr if the index does not exist.
Expand Down Expand Up @@ -298,13 +314,19 @@ namespace sdf
/// \param[in] _name Name of the placement frame.
public: void SetPlacementFrameName(const std::string &_name);

/// \brief Give a weak pointer to the PoseRelativeToGraph to be used
/// for resolving poses. This is private and is intended to be called by
/// \brief Give the scoped PoseRelativeToGraph to be used for resolving
/// poses. This is private and is intended to be called by World::Load and
/// Model::Load if this is a nested model.
/// \param[in] _graph scoped PoseRelativeToGraph object.
private: void SetPoseRelativeToGraph(
sdf::ScopedGraph<PoseRelativeToGraph> _graph);

/// \brief Give the scoped FrameAttachedToGraph to be used for resolving
/// attached bodies. This is private and is intended to be called by
/// World::Load and Model::Load if this is a nested model.
/// \param[in] _graph Weak pointer to PoseRelativeToGraph.
/// \return Error if graph pointer is invalid.
private: sdf::Errors SetPoseRelativeToGraph(
std::weak_ptr<const PoseRelativeToGraph> _graph);
/// \param[in] _graph scoped FrameAttachedToGraph object.
private: void SetFrameAttachedToGraph(
sdf::ScopedGraph<FrameAttachedToGraph> _graph);
scpeters marked this conversation as resolved.
Show resolved Hide resolved

/// \brief Get the model's canonical link and the nested name of the link
/// relative to the current model, delimited by "::".
Expand All @@ -313,7 +335,8 @@ namespace sdf
private: std::pair<const Link *, std::string> CanonicalLinkAndRelativeName()
const;

/// \brief Allow World::Load to call SetPoseRelativeToGraph.
/// \brief Allow World::Load to call SetPoseRelativeToGraph and
/// SetFrameAttachedToGraph
friend class World;

/// \brief Allow helper function in FrameSemantics.cc to call
Expand Down
23 changes: 21 additions & 2 deletions include/sdf/SemanticPose.hh
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ namespace sdf
// Forward declare private data class.
class SemanticPosePrivate;
struct PoseRelativeToGraph;
template <typename T> class ScopedGraph;

/// \brief SemanticPose is a data structure that can be used by different
/// DOM objects to resolve poses on a PoseRelativeToGraph. This object holds
Expand Down Expand Up @@ -78,12 +79,30 @@ namespace sdf
/// raw pose is applied.
/// \param[in] _defaultResolveTo Default frame to resolve-to in Resolve()
/// if no frame is specified.
/// \param[in] _graph Weak pointer to PoseRelativeToGraph.
/// \param[in] _graph A scoped PoseRelativeToGraph object.
private: SemanticPose(
const ignition::math::Pose3d &_pose,
const std::string &_relativeTo,
const std::string &_defaultResolveTo,
std::weak_ptr<const sdf::PoseRelativeToGraph> _graph);
const sdf::ScopedGraph<sdf::PoseRelativeToGraph> &_graph);

/// \brief Private constructor that is used by object that represent a frame
/// in the PoseRelativeTo graph. Examples are Model, Frame, Link and not
/// Collision or Visual.
/// \param[in] _name Name of object. This should also be the name of the
/// frame represented by this object in the PoseRelativeTo graph.
/// \param[in] _pose Raw pose of object.
/// \param[in] _relativeTo Name of frame in graph relative-to which the
/// raw pose is applied.
/// \param[in] _defaultResolveTo Default frame to resolve-to in Resolve()
/// if no frame is specified.
/// \param[in] _graph A scoped PoseRelativeToGraph object.
private: SemanticPose(
const std::string &_name,
const ignition::math::Pose3d &_pose,
const std::string &_relativeTo,
const std::string &_defaultResolveTo,
const sdf::ScopedGraph<sdf::PoseRelativeToGraph> &_graph);

/// \brief Destructor
public: ~SemanticPose();
Expand Down
10 changes: 6 additions & 4 deletions include/sdf/Sensor.hh
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
#include "sdf/Element.hh"
#include "sdf/SemanticPose.hh"
#include "sdf/Types.hh"
#include "sdf/sdf_config.h"
#include "sdf/system_util.hh"

namespace sdf
Expand All @@ -40,6 +41,7 @@ namespace sdf
class Magnetometer;
class SensorPrivate;
struct PoseRelativeToGraph;
template <typename T> class ScopedGraph;

/// \enum SensorType
/// \brief The set of sensor types.
Expand Down Expand Up @@ -315,12 +317,12 @@ namespace sdf
/// \param[in] _xmlParentName Name of xml parent object.
private: void SetXmlParentName(const std::string &_xmlParentName);

/// \brief Give a weak pointer to the PoseRelativeToGraph to be used
/// for resolving poses. This is private and is intended to be called by
/// \brief Give the scoped PoseRelativeToGraph to be used for resolving
/// poses. This is private and is intended to be called by
/// Link::SetPoseRelativeToGraph.
/// \param[in] _graph Weak pointer to PoseRelativeToGraph.
/// \param[in] _graph scoped PoseRelativeToGraph object.
private: void SetPoseRelativeToGraph(
std::weak_ptr<const PoseRelativeToGraph> _graph);
sdf::ScopedGraph<PoseRelativeToGraph> _graph);

/// \brief Allow Link::SetPoseRelativeToGraph to call SetXmlParentName
/// and SetPoseRelativeToGraph, but Link::SetPoseRelativeToGraph is
Expand Down
Loading