MeshDMP: Motion Planning on Discrete Manifolds using Dynamic Movement Primitives