[vtkusers] How to set a normal of a cell?
David Doria
daviddoria at gmail.com
Mon Jun 8 10:11:49 EDT 2009
On Mon, Jun 8, 2009 at 9:30 AM, vtklearny <msjean at gmx.de> wrote:
>
> Hello there,
>
> I'm still new to vtk and after some point manipulation I have to
> modify/update the normals.
>
> I found out that I can access the vtkCells , giving me 3 points in return.
> Then I can calculate a normal vector.
>
> But how do I set the vtkCell's(which is also a vtkTriangle) normal to my
> calculated one ?
> Is there something like this? : vtkCellData->setCellsNormal(cellId,
> normal);
>
> I thought there was a way to invoke automatic normal computation but never
> saw that working.
>
> Thanks for any help.
> I did not find an answer to this anywhere.
>
> the vtklearny
>
I just put this up on the wiki:
http://www.vtk.org/Wiki/Point_and_Cell_Normals
Is this what you are looking for?
The vtkPolyDataNormals class (demonstrated here:
http://www.vtk.org/Wiki/Extract_Normals_from_a_Polydata ) does what it
sounds like you are trying to do automatically.
Let us know if you have any more problems.
Thanks,
David
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20090608/7961247c/attachment.htm>
More information about the vtkusers
mailing list