[vtkusers] Getting corresponding points from ICP Transform.

David Doria daviddoria at gmail.com
Thu Mar 10 09:58:34 EST 2016


On Thu, Mar 10, 2016 at 8:03 AM, Xentro <rubengysemans at hotmail.com> wrote:

> Hey there,
>
> I need to fit two smaller datasets to a larger one by first using ICP to
> match them onto the larger data set and then use a least squares landmark
> transform to align them with the larger piece. Now for the landmark
> transform i need two datasets of corresponding points. ICP should calculate
> this for me but how do I get the data from the ICP transform to input into
> LandmarkTransform? I know I can get a celllocator from the ICP class but I
> have no idea what this locator contains or how to use it.
>
> Regards, Xentro
>

Are you just looking for the transform matrix that the ICP filter computes?
If so:

vtkSmartPointer<vtkMatrix4x4> transformMatrix =
iterativeClosestPointTransform->GetMatrix();

See this example for how to then transform one of your point sets using
vtkTransformPolyDataFilter:

http://www.vtk.org/Wiki/VTK/Examples/Cxx/Filters/IterativeClosestPointsTransform

David
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/vtkusers/attachments/20160310/c0485660/attachment.html>


More information about the vtkusers mailing list