[ROS2] Node pointer from a LifecycleNode
Hi all,
the problem of LifecycleNode pointers support comes back.
Using ROS2 Bouncy I could not directly publish TF because the broadcaster creator requires only a rclcpp::Node pointer as initialization parameter [see the related post]
In ROS2 Crystal the problem reappears with image_transport.
Indeed also the functions image_transport::create_publisher
and image_transport::create_camera_publisher
can be initialized only using a rclcpp::Node
pointer.
LifecycleNode is a very useful feature introduced in ROS2, but developers think yet with an eye on ROS1 and they do not take care about the new kind of nodes...
I think that this is a very annoying problem.
PS the only solution that I can imagine is to create a rclcpp::Node
component that subscribes to sensor_msgs::msg::Image
topics and republish them using image_transport
... this is absurd ;)
Asked by Myzhar on 2019-01-16 04:20:59 UTC
Comments
Have you heard anything with regards to this?
Asked by surfertas on 2019-08-11 22:49:31 UTC
There is an open ticket for image transport: https://github.com/ros-perception/image_common/issues/108 I believe the same changes as for geometry2 can easily be applied for the image transport.
Asked by Karsten on 2019-08-12 12:00:03 UTC
@Karsten Can you reference the link to the changes in geometry2? Thank you.
Asked by surfertas on 2019-08-12 21:25:26 UTC
PR108, i.e. changes like these: https://github.com/ros2/geometry2/pull/108/files#diff-091c59f4fa0421742ec1140ca6cad3dcR74-R102 Essentially everything which was a
rclcpp::Node
before becomes a templatedNode &&
. The free functions likerclcpp::create_subscription
take anything "node-like".Asked by Karsten on 2019-08-12 22:41:59 UTC
Any news about this? @Karsten @surfertas
Asked by Myzhar on 2020-01-21 11:18:58 UTC
I don't have any updates on this rather than what I mentioned earlier, that a change to make this work shouldn't be too complicated. I propose to continue the conversation on the referenced github ticket.
Asked by Karsten on 2020-01-21 16:54:30 UTC