[vtk-developers] [Urgent help] Construct a 3d nucleus surface using VTK
mersa88
melissagoh27 at gmail.com
Sat Mar 3 02:45:26 EST 2012
I am trying to construct a three-dimensional nucleus surface in VTK but it
doesn't seems right. Can anyone please advise? Thanks a lot!
/vtkPolyData strip = new vtkPolyData();
vtkPoints points = new vtkPoints();
for (int i=0; i<xyz.length; i++)
points.InsertNextPoint(xyz[i][0], xyz[i][1], xyz[i][2]); //in terms of
x,y,z
strip.SetPoints(points);
vtkSurfaceReconstructionFilter surface = new
vtkSurfaceReconstructionFilter();
surface.SetInput(strip);
vtkContourFilter cf = new vtkContourFilter();
cf.SetInputConnection(surface.GetOutputPort());
vtkReverseSense reverse = new vtkReverseSense();
reverse.SetInputConnection(cf.GetOutputPort());
reverse.ReverseCellsOn();
reverse.ReverseNormalsOn();
reverse.Update();
vtkPolyDataMapper map = new vtkPolyDataMapper();
map.SetInput(reverse.GetOutput());
map.ScalarVisibilityOff();</i>
http://vtk.1045678.n5.nabble.com/file/n5533276/training_pattern.jpg
--
View this message in context: http://vtk.1045678.n5.nabble.com/Urgent-help-Construct-a-3d-nucleus-surface-using-VTK-tp5533276p5533276.html
Sent from the VTK - Dev mailing list archive at Nabble.com.
More information about the vtk-developers
mailing list