ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | Q&A answers.ros.org
Ask Your Question
0

How to get a marker to move with its reference frame?

asked 2021-11-04 21:24:40 -0500

jasr gravatar image

Hi, I'm learning how to use markers in rviz, currently using ros noetic. I successfully created a marker and can get it to show in rviz just fine, but when I move my model the marker stays in the same place in the space, it doesn't follow its reference frame. Any idea on how to fix this and get the marker moving with its respective reference frame?

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
1

answered 2021-11-05 00:14:38 -0500

mcevoyandy gravatar image

updated 2021-11-05 00:15:23 -0500

are you using the frame_locked parameter of the Marker msg?

edit flag offensive delete link more

Comments

Thanks, that's exactly what I needed!

jasr gravatar image jasr  ( 2021-11-05 18:20:52 -0500 )edit

As the user mcevoyandy commented, al I needed to do is to add the frame_locked parameter, so with only this set as true, the marker moves keeping its position relative to its reference frame:

self.marker_object.frame_locked = True

jasr gravatar image jasr  ( 2021-11-05 18:23:40 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 2021-11-04 21:24:40 -0500

Seen: 35 times

Last updated: Nov 05 '21