MarkerArray renders in the wrong position #1050
-
Found a strange bug in rendering visualization_msgs/msg/MarkerArray. Attached are two bags in a zip file, and a layout to make the bug obvious. If you open
The behavior I would expect here is the one seen in the shorter bag, where the arrows appear in the same space as the custom grid. That is how this appears in rviz. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 1 reply
-
Tracking issue: https://linear.app/foxglove/issue/FG-9260/markerarray-renders-in-the-wrong-position |
Beta Was this translation helpful? Give feedback.
-
Hello, we took a look and spotted the problem: your header timestamps in your MarkerArray messages is zero, whereas Foxglove uses this timestamp to determine where to place your markers in the scene by referencing your transforms. This explains why the shorter recording works: it starts when the To get the expected behavior, you'd need to publish your MarkerArrays with the appropriate timestamp, e.g., publish time. Let me know if that makes sense. |
Beta Was this translation helpful? Give feedback.
Hello, we took a look and spotted the problem: your header timestamps in your MarkerArray messages is zero, whereas Foxglove uses this timestamp to determine where to place your markers in the scene by referencing your transforms.
This explains why the shorter recording works: it starts when the
BASE
frame is in a fixed position for the rest of the recording. The longer recording has some early movement that is cut off in the shorter one. The timestamp being 0 for all MarkerArray messages, Foxglove matches up where to place the markers with the first available transform message.To get the expected behavior, you'd need to publish your MarkerArrays with the appropriate timestamp, e.g., pub…