<div dir="ltr"><div><div>Hi Zein, attached is the example I have modified (there are some errors in the wiki example). In TestImageInterpolator.cxx you can see that there are 2 loops one for spans and the inner along the span. If you execute the example you should obtain the following output. In this sample image there two slices with size 4x3.<br><br>val: 0 0 0 0<br>val: 0 0 0 0<br>val: 0 0 0 0<br>val: 1 1 1 1<br>val: 1 1 1 1<br>val: 1 1 1 1<br><br></div>best regards,<br><br><br></div>Jorge<br><div><div><br></div></div></div><div class="gmail_extra"><br><div class="gmail_quote">2014-10-16 13:07 GMT+02:00 Zein Salah <span dir="ltr"><<a href="mailto:zeinsalah@gmail.com" target="_blank">zeinsalah@gmail.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div><div>well Jorge,<br><br>this is actually what I am trying to understand.<br><br></div>it seems the example works for 2d images. since I am using a similar code and it does not iterate in the third dimension,<br><br></div>are spans meat to be slices?<br></div><div class="HOEnZb"><div class="h5"><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Oct 16, 2014 at 12:23 PM, Jorge Perez <span dir="ltr"><<a href="mailto:josp.jorge@gmail.com" target="_blank">josp.jorge@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div><div>Hi, you can see how it is used in this example <br><br><a href="http://www.vtk.org/Wiki/VTK/Examples/Cxx/Broken/ImageData/vtkImageIterator" target="_blank">http://www.vtk.org/Wiki/VTK/Examples/Cxx/Broken/ImageData/vtkImageIterator</a><br><br></div>regards,<br><br></div>Jorge<br></div><div class="gmail_extra"><br><div class="gmail_quote"><div><div>2014-10-16 12:18 GMT+02:00 Zein Salah <span dir="ltr"><<a href="mailto:zeinsalah@gmail.com" target="_blank">zeinsalah@gmail.com</a>></span>:<br></div></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div><div dir="ltr"><div><div><div><div>Hi,<br><br></div>I have an understanding problem, I think I am missing something.<br>what is a span iterator within the vtk image iterator? what is it needed for?<br></div>I need to only iterate over an extent in the image and access data values<br></div>within it. How should I move the iterator to the next position? how to access<br></div>the underlying data?<br><br>thx<br><div><div><div><br></div></div></div></div>
<br></div></div>_______________________________________________<br>
Powered by <a href="http://www.kitware.com" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
<br>
Please keep messages on-topic and check the VTK FAQ at: <a href="http://www.vtk.org/Wiki/VTK_FAQ" target="_blank">http://www.vtk.org/Wiki/VTK_FAQ</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://public.kitware.com/mailman/listinfo/vtkusers" target="_blank">http://public.kitware.com/mailman/listinfo/vtkusers</a><br>
<br></blockquote></div><br></div>
</blockquote></div><br></div>
</div></div></blockquote></div><br></div>