[vtkusers] vtkTriangleFilter
AirWalker
air at freemail.hu
Fri Mar 9 08:38:02 EST 2007
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Hi there,
I have lot of 3D points. I want to make a nice mesh, but if I apply
vtkTriangleFilter the render window is empty...
here's the code:
points = vtk.vtkPoints()
file=argv[1]
befile=open(file,'r')
sorok=0
for sor in fileinput.input(file):
sor=sor.split(',')
points.InsertPoint(sorok,float(sor[0]),float(sor[1]),float(sor[2]))
sorok=sorok+1
cutPoly = vtk.vtkPolyData()
cutPoly.SetPoints(points)
cutTriangles = vtk.vtkTriangleFilter()
cutTriangles.SetInput(cutPoly)
cutMapper = vtk.vtkPolyDataMapper()
cutMapper.SetInput(cutPoly)
cutMapper.SetInputConnection(cutTriangles.GetOutputPort())
cutActor = vtk.vtkActor()
cutActor.SetMapper(cutMapper)
any idea?
thanks,
air
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.5 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
iD8DBQFF8WM6Hql4/uqDsvsRAhUPAJ0dMVbWHl7Ec7PYO3vxAAUeBNJyMACgso5M
1FQuiS8+CYQiRH1bDldvo5k=
=MWkn
-----END PGP SIGNATURE-----
More information about the vtkusers
mailing list