<br>Uhm not sure but maybe you need to check something like <font size="-1">vtkContourFilter ?<br>I don't know what you want to do... i play mostly with vtkTransformPolyDataFiler <br>or vtkTransformFilter. They both return structured polydata. <br><br></font><b><i>学志 杨 &lt;shulo1978@hotmail.com&gt;</i></b> wrote:<blockquote class="replbq" style="border-left: 2px solid rgb(16, 16, 255); margin-left: 5px; padding-left: 5px;"> <br>Thank you. It does work. By the way, do you know any filter like <br>threshfilter can filter vtkPolyData but return structured polydata instead <br>of unstructured? Cheers<br><br>&gt;From: Emmanouil Moschidis <moshman65@yahoo.com><br>&gt;To: "学志" "杨" <shulo1978@hotmail.com><br>&gt;CC: vtkusers@vtk.org<br>&gt;Subject: Re: [vtkusers] how to construct vktCell with vtkPoints<br>&gt;Date: Tue, 1 May 2007 04:38:33 -0700 (PDT)<br>&gt;<br>&gt;Hi<br>&gt;this is a piece of code that should work...<br>&gt;<br>&gt;     vtkPoints *cloudPoints=new
 vtkPoints;<br>&gt;     vtkCellArray *cloudCells=new vtkCellArray;<br>&gt;     vtkPolyData *cloudPData=new vtkPolyData;<br>&gt;<br>&gt;<br>&gt;     cloudPoints-&gt;SetDataTypeToDouble();<br>&gt;     cloudPoints-&gt;SetNumberOfPoints(numberOfVTKPoints);<br>&gt;<br>&gt;<br>&gt;     for(int i=0; i&lt;(numberOfVTKCells*3); i++)<br>&gt;     {<br>&gt;         <br>&gt;cloudPoints-&gt;SetPoint(i,vtkStoredPointsBuffer[i].getX(),vtkStoredPointsBuffer[i].getY(),vtkStoredPointsBuffer[i].getZ());<br>&gt;<br>&gt;     }<br>&gt;<br>&gt;<br>&gt;     cloudCells-&gt;InsertNextCell(numberOfVTKPoints);<br>&gt;<br>&gt;<br>&gt;     for (int i=0; i<numberOfVTKPoints; i++)=""><br>&gt;     {<br>&gt;         cloudCells-&gt;InsertCellPoint(i);<br>&gt;     }<br>&gt;<br>&gt;<br>&gt;     cloudPData-&gt;SetPoints(cloudPoints);<br>&gt;     cloudPData-&gt;SetLines(cloudCells);<br>&gt;<br>&gt;<br>&gt;the only weird thing you may see is these getX(), getY(), getZ() methods. <br>&gt;The reason why i use these
 methods is that i store my points in <br>&gt;std::vector<Point3D><br>&gt;where Point3D is a custom class for 3D points (in your case you use <br>&gt;vtkPoints).<br>&gt;<br>&gt;Try it and tell me if it worked. I am not 100% this is the correct way <br>&gt;though<br>&gt;<br>&gt;Good luck :-)<br>&gt;<br>&gt;<br>&gt;<br>&gt;学志 杨 <shulo1978@hotmail.com> wrote: Hi all, I extract vtkpoints from a <br>&gt;polydata and want to reconstruct them<br>&gt;back into vtkCell. Can anyone give me some hint to do this? The points are<br>&gt;taken out based on some conditions so I can't use getCell from vtkpolydata<br>&gt;to take the cell straignthaway. Thank you!<br>&gt;<br>&gt;_________________________________________________________________<br>&gt;Could you be the guest MSN Movies presenter? Click Here to Audition<br>&gt;http://www.lightscameraaudition.co.uk<br>&gt;<br>&gt;_______________________________________________<br>&gt;This is the private VTK discussion list.<br>&gt;Please keep
 messages on-topic. Check the FAQ at: <br>&gt;http://www.vtk.org/Wiki/VTK_FAQ<br>&gt;Follow this link to subscribe/unsubscribe:<br>&gt;http://www.vtk.org/mailman/listinfo/vtkusers<br>&gt;<br>&gt;<br>&gt;<br>&gt;---------------------------------<br>&gt;Ahhh...imagining that irresistible "new car" smell?<br>&gt;  Check outnew cars at Yahoo! Autos.<br><br>_________________________________________________________________<br>Txt a lot? Get Messenger FREE on your mobile.  <br>https://livemessenger.mobile.uk.msn.com/<br><br></shulo1978@hotmail.com></Point3D></numberOfVTKPoints;></shulo1978@hotmail.com></moshman65@yahoo.com></blockquote><br><p>&#32;



      <hr size=1>Ahhh...imagining that irresistible "new car" smell?<br> Check out
<a href="http://us.rd.yahoo.com/evt=48245/*http://autos.yahoo.com/new_cars.html;_ylc=X3oDMTE1YW1jcXJ2BF9TAzk3MTA3MDc2BHNlYwNtYWlsdGFncwRzbGsDbmV3LWNhcnM-">new cars at Yahoo! Autos.</a>