A nodelet mixin that allows to use a tf2_ros::Buffer provided by the nodelet manager (which should save some computations). If this nodelet has also the StatefulNodelet mixin, the automatically created non-shared buffer is nodelet-aware (you can also pass a NodeletAwareTfBuffer to setBuffer()). That means any TF lookups done via this->getBuffer() will be able to correctly end when the nodelet is being unloaded (which normally hangs: https://github.com/ros/geometry2/issues/381).
More...
#include <nodelet_with_shared_tf_buffer.hpp>
|
| ::std::unique_ptr<::cras::impl::NodeletWithSharedTfBufferPrivate > | data |
| | PIMPL. More...
|
| |
template<typename NodeletType = ::nodelet::Nodelet>
struct cras::NodeletWithSharedTfBuffer< NodeletType >
A nodelet mixin that allows to use a tf2_ros::Buffer provided by the nodelet manager (which should save some computations). If this nodelet has also the StatefulNodelet mixin, the automatically created non-shared buffer is nodelet-aware (you can also pass a NodeletAwareTfBuffer to setBuffer()). That means any TF lookups done via this->getBuffer() will be able to correctly end when the nodelet is being unloaded (which normally hangs: https://github.com/ros/geometry2/issues/381).
- Template Parameters
-
| NodeletType | Type of the base nodelet. |
Definition at line 69 of file nodelet_with_shared_tf_buffer.hpp.
◆ NodeletWithSharedTfBuffer()
template<typename NodeletType = ::nodelet::Nodelet>
◆ ~NodeletWithSharedTfBuffer()
template<typename NodeletType = ::nodelet::Nodelet>
◆ getBuffer()
template<typename NodeletType = ::nodelet::Nodelet>
Get the TF buffer used by the nodelet. If none has been set by setBuffer(), a buffer is automatically created.
- Returns
- The buffer.
- Note
- This buffer is only offers the timeouting versions of canTransform() and lookupTransform(). It does not offer setTransform() and many other functions. User getRawBuffer() on the returned instance to get a tf2::BufferCore that offers the missing non-time-aware functionality.
Implements cras::NodeletWithSharedTfBufferInterface.
◆ setBuffer()
template<typename NodeletType = ::nodelet::Nodelet>
◆ usesSharedBuffer()
template<typename NodeletType = ::nodelet::Nodelet>
◆ data
template<typename NodeletType = ::nodelet::Nodelet>
The documentation for this struct was generated from the following file: