[vtkusers] Using vtkFillHolesFilter on meshes

Bryn Lloyd lloyd at itis.ethz.ch
Wed Apr 20 16:06:37 EDT 2011


Hi

It looks like you should use an array of length cellarray->getmaxcellsize(), ie use
vtkIdType pointsId[maxcellsize];


--

On 20.04.2011, at 20:37, Bill Lorensen <bill.lorensen at gmail.com> wrote:

> Can you post the code that uses FillHolesFilter?
> 
> On Wed, Apr 20, 2011 at 11:12 AM, KK <karoll.frindel at gmail.com> wrote:
>> Can someone explain me how this filter works.
>> I try in vain to apply it to one of my meshes, but I get a vtkPolyData in
>> output (m_poly) that does not seem to be a mesh in my opinion ...
>> When I execute the following piece of code:
>>   vtkSmartPointer <vtkCellArray> cellArray = m_poly-> GetPolys ();
>>   int = iNbT cellArray-> GetNumberOfCells ();
>>   int = iNbPts m_poly-> GetPoint () -> GetNumberOfPoints ();
>>   double point [3];
>>   for (int i = 0; i &lt;iNbT; i + +)
>>   {
>>       p_Triangles [i] = new sint [3];
>>       vtkIdType npts = 0, * pointsId = NULL;
>>       cellArray-&gt; GetNextCell (npts, pointsId);
>>       ...
>>    }
>> 
>> npts is 0 while I supposed it should equal 3 so that the cell describe a
>> triangle.
>> Does anyone has an answer to this problem. Thank you in advance!
>> 
>> --
>> View this message in context: http://vtk.1045678.n5.nabble.com/Using-vtkFillHolesFilter-on-meshes-tp4328350p4328350.html
>> Sent from the VTK - Users mailing list archive at Nabble.com.
>> _______________________________________________
>> Powered by www.kitware.com
>> 
>> Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html
>> 
>> Please keep messages on-topic and check the VTK FAQ at: http://www.vtk.org/Wiki/VTK_FAQ
>> 
>> Follow this link to subscribe/unsubscribe:
>> http://www.vtk.org/mailman/listinfo/vtkusers
>> 
> _______________________________________________
> Powered by www.kitware.com
> 
> Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html
> 
> Please keep messages on-topic and check the VTK FAQ at: http://www.vtk.org/Wiki/VTK_FAQ
> 
> Follow this link to subscribe/unsubscribe:
> http://www.vtk.org/mailman/listinfo/vtkusers
> 



More information about the vtkusers mailing list