[vtkusers] write a specific point's normal of polyData

David Doria daviddoria at gmail.com
Tue Mar 13 08:07:10 EDT 2012


> questions:
> -------------
> 1. why the following window of vtk appears with this massage ?
>       "vtkFieldData::GetComponent was deprecated for vtk 5.2 and will be
> removed "

Why you are using GetComponent? You should probably use

 double arr[3];
 m_normalGenerator->GetOutput()->GetPointData()->GetNormals()->GetTupleValue(idx,
arr);

instead.

> 2. what's the difference between calculating cell/point normals?

If you compute point normals, a normal is produced at every point in
the PointData. If you compute cell normals,  a normal is produced at
every cell in the CellData.

> 3. regarding the vtkXMLPolyDataWriter:
>       - why the .vtp represents in 3d Glyphse arrows in the same direction
> as the surface and not in the orthogonal plane as supposed to be? (image
> attached)

Your screenshot does not include the relevant portion of the window to
show us your settings. My bet is that you did not set the glyphs to
use the normals.

David



More information about the vtkusers mailing list