[vtkusers] Match two meshes without collision
David Doria
daviddoria at gmail.com
Fri Dec 16 08:24:02 EST 2011
On Fri, Dec 16, 2011 at 4:50 AM, Laurent <l.paul at uclouvain.be> wrote:
> That's not what I meant, I d'ont want to match overlapping parts of meshes.
> I want to match two surfaces (the moving one is a subpart of a closed mesh)
> and check if there is no local minimum id. a wrong positionning of the
> subpart.
> To do so, I have to prevent the meshes from colliding themselves.
> Unfortunatelly, that's what IterativeClosestPoint does since it computes the
> distance between meshes whatever it be positive (point is outside the closed
> fixed mesh) or negative (point is inside the closed fixed mesh).
> I think that the clue is the landmarkTransform used by the
> IterativeClosestPoint algo. I have to constraint the transform to put the
> moving mesh in the closest outside position to the fixed mesh instead of the
> absolute closest position.
>
> I can't remove points that lie inside the fixed mesh since they have to be
> involved for the next transform computation to put the moving mesh outside.
>
> Any new idea?
> Thx,
> Laurent.
You could compute the signed distance between the meshes using:
http://www.vtk.org/Wiki/VTK/Examples/Cxx/PolyData/DistancePolyDataFilter
and use that as the inner loop of the ICP.
David
More information about the vtkusers
mailing list