Low-level access to triangle faces of mesh
Is there any API to access triangle faces of a particular mesh ?
I want to implement a boat dynamics plugin that realistically deals with water-hull interaction.
Specifically, I want to mimic water interaction model for boats in video games. My idea is to compute water-hull interaction forces and apply it as wrench to the root link element of the boat model.
Here water is just going to be a grid of points that move up and down. The faces constructed by joining them serves as the uneven water surface. The hull of the boat is going to be a V shaped extrusion (much like a business card bent in half).
If Gazebo does not provide such functions, are there any robotics oriented simulator that may suit my needs.
Asked by pradeepr on 2016-12-05 02:51:10 UTC
Answers
That sounds like an awesome project!
You can use the MeshManager to get the mesh for your boat. The Mesh class has the API you're looking for, which gives access to vertices, normals, etc.
You'll probably also need to use the physics API to apply forces to your boat model.
Asked by chapulina on 2016-12-06 12:01:46 UTC
Comments
I looked into the MeshManager class. It seems to be the right way to go. Thanks for the suggestion.
I believe I need to use the GetMesh function. Naturally, it requires a Mesh name string to be given as a parameter.
I am sure I need to use the GetName function of the Link object. But, how do I get the mesh name/names associated with a link.
Asked by pradeepr on 2016-12-06 14:22:50 UTC
Have you made any progress on the boat dynamics plugin? It's exactly what I'm embarking on...
Asked by tve on 2017-08-11 15:08:21 UTC
Comments