# rviz odometry plugin does not respect keep value

It seems that if the frame in which the odometry is displayed is the same (or fixed wrt) the rviz global option fixed frame, then only one odometry is drawn...

My intuition is that the distance computation between current position and last drawn position (to compare to tolerance and decide if we draw a new arrow), is made in the rviz fixed frame, so in my case, the values does not change (even if the robot is moving).

edit retag close merge delete

It indeed uses the value configured for Fixed Frame (here), but doesn't seem to be used for delta calculation though.

To me it's not clear whether you have some special Odometry publisher that would require something else.

It might help others (and me, but I'm not really into this kind of thing) if you could provide a little more information about your specific setup, as:

in my case, the values does not change (even if the robot is moving).

implies that you have some circumstance which would require RViz to do something differently.

Note that it could also be that whatever is publishing your odometry messages is doing something non-standard, but at this point I believe we can't say.

( 2019-10-09 05:39:59 -0500 )edit

I think I see where my problem is coming from. I used the robot frame as "fixed frame", so in this frame, odometry difference between two positions will be null.

(last_position - current_position).length()  will always be equal to zero, no?


Sorry for the disturbance...

PS: I had this setup because I started to use rviz to display PointCloud2 in the still robot frame... but now that the robot is moving, I should use another "fixed frame"

PPS: not to mention that the rviz documentation says: For correct results, the fixed frame should not be moving relative to the world.

( 2019-10-09 06:38:48 -0500 )edit