[vtkusers] Normal of a point
Obada Mahdi
omahdi at gmx.de
Tue Dec 12 07:52:55 EST 2006
Hi Tony!
On 12/10/06, tony hakki <tony2007vtk at yahoo.com> wrote:
> I want to get normal vector of point around a cell/polygon in my vtk class,
> and I will have some points on that normal vector, and also I will get those
> points density values. How can I obtain these with VTK (c++), Does anybody
> have a such kind of example?
I don't have an example at hands, but maybe some pointers will help
for getting started:
Generating point normals:
vtkPolyDataNormals computes point normals from cell information in a
polydata set
http://www.vtk.org/doc/nightly/html/classvtkPolyDataNormals.html
Pushing points along their associated normal vector:
vtkWarpScalar can be used for generating points from an input data set
by translating the source points along their normal vectors
http://www.vtk.org/doc/nightly/html/classvtkWarpScalar.html
Obtaining data attributes at specific point positions:
vtkProbeFilter takes an input data set (for instance, your generated
point set) and computes data attributes, like scalars--which might be
representing density values in your case--by interpolating them from a
source data set (say, image data representing a volume)
http://www.vtk.org/doc/nightly/html/classvtkProbeFilter.html
There might be examples in the VTK source tree demonstrating the use
of some of these classes.
HTH,
Obada
More information about the vtkusers
mailing list