[vtkusers] Obtaining XYZ Coords
Tron Darvann
trd at odont.ku.dk
Thu Mar 30 06:01:29 EST 2006
Hello,
I tried this:
set points [PolyData GetPoints]
set pointnumber 12
set point [$points GetPoint $pointnumber]
set xp [lindex $point 0]
set yp [lindex $point 1]
set zp [lindex $point 2]
puts stdout "$xp $yp $zp"
This prints the xyz coordinates of point number 12.
Btw. Do you know how to do the same with the polygons in tcl (e.g. getting point numbers for polygon number i)
Tron Darvann
Tron Darvann
Research Engineer, 3D-Laboratory
Tel: (+45) 35 32 67 58 (lab) / (+45) 28 20 03 12 (mobile)
E-mail: trd at odont.ku.dk or tdarvann at lab3d.odont.ku.dk
Mailing and Visiting Address:
3D-Lab, School of Dentistry
University of Copenhagen
Nørre Alle 20
DK-2200 Copenhagen N
Denmark
________________________________
Fra: vtkusers-bounces+trd=odont.ku.dk at vtk.org på vegne af B.J.Prosser at cs.cardiff.ac.uk
Sendt: to 30-03-2006 12:20
Til: vtkusers at vtk.org
Emne: [vtkusers] Obtaining XYZ Coords
Im trying to get the xyz coords (individually) from points in a mesh (using tcl)
Ive got as far as:
set points [[smoother GetOutput] GetPoints]
set point *[$points GetPoint $x]
but how do i then get from the vtkPoint point to the x, y and z numbers
thanks
_______________________________________________
This is the private VTK discussion list.
Please keep messages on-topic. Check the FAQ at: http://www.vtk.org/Wiki/VTK_FAQ
Follow this link to subscribe/unsubscribe:
http://www.vtk.org/mailman/listinfo/vtkusers
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20060330/fcb17537/attachment.htm>
More information about the vtkusers
mailing list