<div dir="ltr"><div>Wow, your code works like a charm. I only had to delete the definition "double" below each double array variable declaration.</div><div><br></div><div>Now, last question, I have a count of 1279226 Cells.. pa, pb and pc are 3 Points in that Cell or how is it? How many points a cell has?</div>
</div><div class="gmail_extra"><br><br><div class="gmail_quote">On Wed, Jan 15, 2014 at 2:49 PM, David Gobbi <span dir="ltr"><<a href="mailto:david.gobbi@gmail.com" target="_blank">david.gobbi@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">I think you are just missing this final piece inside your loop:<br>
<br>
  {<br>
<br>
    ...<br>
    double[] pa = new double[3];<br>
    double pa = polys.GetPoint(a);<br>
    double[] pb = new double[3];<br>
    double pb = polys.GetPoint(b);<br>
    double[] pc = new double[3];<br>
    double pc = polys.GetPoint(c);<br>
  }<br>
<br>
The details of the syntax are just guesswork on my part, because I've<br>
never used C# or Activiz.<br>
<span class="HOEnZb"><font color="#888888"><br>
  David<br>
</font></span><div class="HOEnZb"><div class="h5"><br>
On Wed, Jan 15, 2014 at 9:45 AM, Matias Montroull <<a href="mailto:matimontg@gmail.com">matimontg@gmail.com</a>> wrote:<br>
> Hi,<br>
><br>
> I'm trying to get the Cells out of a PolyData. So far I've done this:<br>
><br>
>               vtkCellArray Cellarray = new vtkCellArray();<br>
>               Cellarray = polys.GetPolys(); //where polys is a vtkpolydata<br>
> instance<br>
>               int numcells = Cellarray.GetNumberOfCells(); //I get the<br>
> number of cells, I want to iterate through each cell..<br>
><br>
> I've done this:<br>
>               vtkIdList idlist = new vtkIdList();<br>
><br>
>               Cellarray.InitTraversal();<br>
><br>
>               for (int j = 0; j < polys.GetNumberOfPolys(); j++)<br>
>               {<br>
>                   Cellarray.GetNextCell(idlist);<br>
><br>
>                   double a = idlist.GetId(0);<br>
>                   double b = idlist.GetId(1);<br>
>                   double c = idlist.GetId(2);<br>
>               }<br>
> but I don't get the points in the cell, what I'm doing wrong?<br>
</div></div></blockquote></div><br></div>