0
$\begingroup$

Rosanswers logo

If I modify for example a mesh file how do I re-load that in a running rviz. Just turning RobotModel on and off did not reload the model.

Also is there an easy way to check if a mesh file is displayble in rviz?


Originally posted by TommyP on ROS Answers with karma: 1339 on 2013-02-22

Post score: 4

$\endgroup$

1 Answer 1

0
$\begingroup$

Rosanswers logo

The next relese of RViz will reload the meshes when you press the 'reset' button in the bottom-left corner. See https://github.com/ros-visualization/rviz/commit/ee6221bd5e5203de76c124b8fef41bf7e5332157

An alternative to updating your robot model is to send a mesh marker. See http://www.ros.org/wiki/rviz/DisplayTypes/Marker#Mesh_Resource_.28MESH_RESOURCE.3D10.29_.5B1.1.2B-.5D


Originally posted by dgossow with karma: 1444 on 2013-02-22

This answer was ACCEPTED on the original site

Post score: 1


Original comments

Comment by TommyP on 2013-02-22:
No, that do not work. That re-load the URDF file but it does not re-load the mesh file. That was the reason I wasted so much time since I noticed that the URDF file was re-loaded and of course assumed that also the mesh file was re-loaded.

Comment by Adolfo Rodriguez T on 2013-02-23:
Apart from refreshing the robot description in the parameter server, you need to trigger a refresh of the Rviz robot model plugin. This is done by deactivating / reactivating the plugin (using the checkbox).

Comment by TommyP on 2013-02-23:
Yes, I know. And that re-loads the URDF file. But it seems like the mesh files is cached. I do not change the file namn of the mehs file. I just change the content of it. And it is not re-loaded if it has been loaded once before. It seems to me that a flag is needed in RobotModel to force re-loading

Comment by dgossow on 2013-02-23:
Indeed, RViz caches all meshes, textures, etc.

Comment by TommyP on 2013-02-23:
So is it impossible to re-load them without re-starting rviz?

Comment by lucasw on 2016-05-24:
It looks like a previous poster tracked down the code responsible (circa 2011) http://answers.ros.org/question/11871/collada-dae-resource-not-updated-in-rviz/ - it would be great to be able force a reload without creating multiple files, maybe a pr can be made out of this.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.