<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
<META content="MSHTML 6.00.5730.11" name=GENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=#ffffff>
<DIV><FONT face=Arial size=2>Dear All:</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2> I just want to visulize a new dataset.
The new dataset only contains the new positions of some mesh vertices, and
others (most of the vertices) will keep their positions unchanged. I knew
exactly all the new positions. I just want to associate the new
position with the original point ID, then visualize the new
dataset.</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial
size=2>/*************************************************************************************************</FONT></DIV>
<DIV><FONT face=Arial size=2> vtkPolyData
*poly=normals->GetOutput(); //original dataset </FONT></DIV>
<DIV><FONT face=Arial size=2> vtkPolyData
*polyNew=vtkPolyData::New(); //new dataset after each
iteration</FONT></DIV>
<DIV><FONT face=Arial size=2><BR> // Create vtkPoints <BR>
vtkPoints* points = vtkPoints::New();<BR>
points->SetNumberOfPoints(numPoints); </FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2> //Create Stripe to define
topology<BR> vtkCellArray
*strips=vtkCellArray::New();<BR> strips->InsertNextCell(numPoints);
</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>if (maxCurvature[i]<-0.10 &&
shapeIndex[i]>=SILowLimit &&
shapeIndex[i]<=SIUpLimit<BR> &&
sphericity[i]<=spLimit)<BR> {<BR> //Get
the new positon and save in
vertexNew, <BR> </FONT></DIV>
<DIV><FONT face=Arial size=2> </FONT><FONT face=Arial
size=2> points->InsertPoint(i,vertexNew); <BR>
trips->InsertCellPoint(i);<BR> // Assign
points and
cells<BR> polyNew->SetPoints(points);<BR>
polyNew->SetPolys(strips);
</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2> }//end of if
(minCurvature[i]>0.0)<BR> else<BR> {<BR> //Get
the vertex<BR> double vertex[3];
<BR> poly->GetPoint(i,vertex);<BR> <BR></FONT><FONT
face=Arial
size=2> points->InsertPoint(i,vertex);<BR> strips->InsertCellPoint(i);<BR> //
Assign points and
cells<BR> polyNew->SetPoints(points);<BR> polyNew->SetStrips(strips);
<BR> }</FONT></DIV>
<DIV><FONT face=Arial size=2> </FONT></DIV>
<DIV><FONT face=Arial
size=2>****************************************************************************************************/</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>The problem is that I could not visualize polyNew
as a polydata which I use for poly successfully.</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>I think it should be caused by the non-proper
polydata structure of polyNew;</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>Please help me to figure out the
problem.</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>Best
Wishes,<BR>-----------------------------------------------------------------<BR>Dongqing
Chen<BR>Ph.D Research Assistant<BR>Rm. 07, Paul C. Lutz Hall<BR>Computer Vision
& Image Processing (CVIP) Lab<BR>Department of Electrical & Computer
Engineering<BR>Speed School of Engineering<BR>University of
Louisville<BR>Louisville, KY. 40292<BR>U.S.A<BR>Email: <A
href="mailto:dqchen@cvip.louisville.edu">dqchen@cvip.louisville.edu</A><BR>Phone:+1-502-852-2789
(Lab)<BR>
+1-502-852-6130
(Office)<BR>-----------------------------------------------------------------</FONT></DIV></BODY></HTML>