srmainwaring / asv_wave_sim

This package contains plugins that support the simulation of waves and surface vessels in Gazebo.
GNU General Public License v3.0
114 stars 31 forks source link

Fix collision pose not accounted for in hydrodynamics plugin #36

Closed srmainwaring closed 2 years ago

srmainwaring commented 2 years ago

This PR fixes the incorrect pose being used for buoyancy calculations when there is an offset of the collision mesh from the link origin.

Fix #35

Test

The objects now float according to the collision mesh (mean position is halfway on the collision sphere) and the inertial is below the centre of pressure = centre of collision sphere.

gzsim_buoyancy_test_4_fix

https://user-images.githubusercontent.com/24916364/170700974-c6b3f3a5-7a1d-4b6a-90b9-17c32693c4f2.mov