Pose2DPublisher QML Type
Publishes geometry_msgs::msg::Pose2D messages — Please use the full 3D pose. More...
| Import Statement: | import QtRos2.GeometryMsgs |
| Inherits: | |
| Status: | Deprecated since Foxy |
This type is deprecated since QtRos2.GeometryMsgs Foxy. We strongly advise against using it in new code.
Properties
Methods
- void publish(pose2D msg)
Detailed Description
In general our recommendation is to use a full 3D representation of everything and for 2D specific applications make the appropriate projections into the plane for their calculations but optimally will preserve the 3D information during processing.
If we have parallel copies of 2D datatypes every UI and other pipeline will end up needing to have dual interfaces to plot everything. And you will end up with not being able to use 3D tools for 2D use cases even if they're completely valid, as you'd have to reimplement it with different inputs and outputs. It's not particularly hard to plot the 2D pose or compute the yaw error for the Pose message and there are already tools and libraries that can do this for you.# This expresses a position and orientation on a 2D manifold.
Pose2DPublisher publishes pose2D values to a ROS 2 topic. Set the topic and node properties, then call publish() to send messages.
See also Pose2DSubscriber and pose2D.
Property Documentation
theta : double
The theta field value included in the next publish. Setting this property emits thetaChanged and, when autoPublish is true, requests a publish at the end of the current event-loop iteration.
x : double
The x field value included in the next publish. Setting this property emits xChanged and, when autoPublish is true, requests a publish at the end of the current event-loop iteration.
y : double
The y field value included in the next publish. Setting this property emits yChanged and, when autoPublish is true, requests a publish at the end of the current event-loop iteration.
Method Documentation
void publish(pose2D msg)
Publishes pose2D msg to the ROS 2 topic set by the topic property. Does nothing if the publisher is not connected.
© 2026 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.