ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange |
1 | initial version |
This is not a ROS question, but a C++ one.
To be able to call an instance of the class B
in your callback, the class TestROSNode
needs to own an instance of the class B
:
class TestROSNode{
private:
ros::Subscriber ik_sub;
B my_b;
void point_callback(const geometry_msgs::Point::ConstPtr& msg){
my_b.dosomething(msg.x):
}
}