[vtkusers] vtkPolyData and replicated vertices in the PointSet list

David.Pont at ForestResearch.co.nz David.Pont at ForestResearch.co.nz
Mon Nov 15 15:33:25 EST 2004





"Ferdinando Rodriguez y Baena" <ferdinando.rodriguez at imperial.ac.uk> wrote
on 16/11/2004 09:08:39:

> Dear users,
>
> I have just realised that vtkPolyData stores triangle information in
> the point list by replicating vertices in the list according to the
> facets index order. I assume this enables fast rendering, which is
> good for display purposes. However, I also intended to use the
> PolyData object as a container for surface information that I need
> for registration. I was expecting to be able to retrieve both vertex
> and polygon information for my closest point search algorithm from
> the PolyData object ( i.e. GetPoints() and GetPolys() ), however it
> appears that the PointSet list has replicated vertices and that the
> facet indices no longer correspond to the correct vertices in the
> PointSet list. By inspecting the source code, I realised that during
> loading of a WaveFront object file (vtkOBJReader.cxx), the original
> vertex index information is lost.
>
> Any idea on how I can retain that information without modifying the
> source code? Or am I simply doing something wrong? Any help would be
> much appreciated.

You could try vtkCleanPolyData, it should get rid of the redundant points
in the data set.
  Dave P

>
> Thank you.
>
> Ferdinando
>  _______________________________________________
> This is the private VTK discussion list.
> Please keep messages on-topic. Check the FAQ at: &lt;http://www.vtk.
> org/Wiki/VTK_FAQ&gt;
> Follow this link to subscribe/unsubscribe:
> http://www.vtk.org/mailman/listinfo/vtkusers




More information about the vtkusers mailing list