RVIZ lags incredibly with a gripper model added in MoveIt MotionPlanning plugin
Dear all,
I'm working with a real 7-DOF arm that's controllable via MoveIt. I operate it in RVIZ and the MotionPlanning plugin. The arm's drivers, MoveGroup and RVIZ are all running on the same machine.
With "Planned Path" parameter "State Display Time" set to REALTIME and animation looped, I click "Plan" and the MotionPlanning plugin displays the trajectory of the arm from current to goal state smoothly.
Now I add a gripper model to the end effector and repeat said steps above. RVIZ becomes extremely slow. The displayed path of the combined arm and gripper model stutters, and cursor navigation of the RVIZ scene drops to ~1 FPS. In htop, the opt/ros/melodic/lib/rviz/rviz process is using 100% CPU.
What is probably of import is the complexity of the anthropomorphic gripper. It's made up of 16 components. At first I thought the lag was caused by the extremely detailed meshes of the gripper components. I thus reduced them to their convex hulls and decimated to <100 vertices each, but to no avail.
What could the reason for this behaviour be? Is MoveIt unable to render that amount of meshes in real time?
It's ultimately rviz that is doing the rendering, but the MoveIt interface plugin could be asking too much. Please post screenshots, the console output of rviz, and bag files of all topics involved, both without and with the gripper.