tf_remapper_node.h
Go to the documentation of this file.
1 #ifndef TF_REMAPPER_NODE_CPP_TF_REMAPPER_H
2 #define TF_REMAPPER_NODE_CPP_TF_REMAPPER_H
3 
4 #include <ros/ros.h>
5 #include <tf2_msgs/TFMessage.h>
6 #include <ros/message.h>
7 
9 
10 namespace tf_remapper_cpp {
11 
24 public:
28 
29  virtual ~TfRemapperNode() {};
30 
31 protected:
38 
39  bool staticTf;
40  tf2_msgs::TFMessage staticTfCache;
41  tf2_msgs::TFMessage reverseStaticTfCache;
42 
43  std::string oldTfTopic;
44  std::string remappedTfTopic;
45 
48 
52 
56 
60  void addToStaticTfCache(const tf2_msgs::TFMessage& message, tf2_msgs::TFMessage& cache) const;
61 };
62 
63 };
64 
65 #endif //TF_REMAPPER_NODE_CPP_TF_REMAPPER_H
tf_remapper_cpp
Definition: tf_remapper.h:7
tf_remapper_cpp::TfRemapperNode
A node that remaps TF frame names according to the given set of rules.
Definition: tf_remapper_node.h:23
tf_remapper_cpp::TfRemapperNode::reverseStaticTfCache
tf2_msgs::TFMessage reverseStaticTfCache
Cache of static TF messages.
Definition: tf_remapper_node.h:41
message.h
ros::Publisher
ros.h
tf_remapper_cpp::TfRemapperNode::oldTfSubscriber
ros::Subscriber oldTfSubscriber
Private ROS node handle.
Definition: tf_remapper_node.h:34
tf_remapper_cpp::TfRemapperNode::publicNodeHandle
ros::NodeHandle publicNodeHandle
Definition: tf_remapper_node.h:29
tf_remapper_cpp::TfRemapperNode::remappedTfTopic
std::string remappedTfTopic
Name of the old topic ("/tf_old").
Definition: tf_remapper_node.h:44
tf_remapper_cpp::TfRemapperNode::privateNodeHandle
ros::NodeHandle privateNodeHandle
ROS node handle.
Definition: tf_remapper_node.h:33
tf_remapper_cpp::TfRemapperNode::reverseTfRemapper
TfRemapper reverseTfRemapper
The remapper that actually changes the TF messages.
Definition: tf_remapper_node.h:47
tf_remapper_cpp::TfRemapperNode::remappedTfPublisher
ros::Publisher remappedTfPublisher
Subscriber to /tf (only in bidirectional mode).
Definition: tf_remapper_node.h:36
tf_remapper_cpp::TfRemapperNode::~TfRemapperNode
virtual ~TfRemapperNode()
Definition: tf_remapper_node.h:29
tf_remapper_cpp::TfRemapperNode::staticTf
bool staticTf
Publisher of /tf_old (only in bidirectional mode).
Definition: tf_remapper_node.h:39
tf_remapper.h
tf_remapper_cpp::TfRemapperNode::addToStaticTfCache
void addToStaticTfCache(const tf2_msgs::TFMessage &message, tf2_msgs::TFMessage &cache) const
Add the given TF message to the static TF cache. Newer TFs overwrite the older ones.
Definition: tf_remapper_node.cpp:102
tf_remapper_cpp::TfRemapperNode::tfRemapper
TfRemapper tfRemapper
Name of the remapped topic ("/tf").
Definition: tf_remapper_node.h:46
tf_remapper_cpp::TfRemapper
Remap frames in TF messages according to given rules.
Definition: tf_remapper.h:10
tf_remapper_cpp::TfRemapperNode::oldTfTopic
std::string oldTfTopic
Cache of static TF messages in the reverse direction.
Definition: tf_remapper_node.h:43
tf_remapper_cpp::TfRemapperNode::oldTfPublisher
ros::Publisher oldTfPublisher
Publisher of /tf.
Definition: tf_remapper_node.h:37
tf_remapper_cpp::TfRemapperNode::staticTfCache
tf2_msgs::TFMessage staticTfCache
If true, this node works with static TF, which need special care.
Definition: tf_remapper_node.h:40
tf_remapper_cpp::TfRemapperNode::oldTfCallback
void oldTfCallback(const ros::MessageEvent< tf2_msgs::TFMessage const > &event)
The remapper that actually changes the TF messages in reverse direction.
Definition: tf_remapper_node.cpp:66
tf_remapper_cpp::TfRemapperNode::remappedTfCallback
void remappedTfCallback(const ros::MessageEvent< tf2_msgs::TFMessage const > &event)
Callback when a TF message arrives on the remapped TF topic.
Definition: tf_remapper_node.cpp:84
tf_remapper_cpp::TfRemapperNode::TfRemapperNode
TfRemapperNode()
Definition: tf_remapper_node.cpp:4
tf_remapper_cpp::TfRemapperNode::remappedTfSubscriber
ros::Subscriber remappedTfSubscriber
Subscriber to /tf_old.
Definition: tf_remapper_node.h:35
ros::NodeHandle
ros::MessageEvent
ros::Subscriber


tf_remapper_cpp
Author(s): Martin Pecka
autogenerated on Mon May 2 2022 02:25:06