<div dir="ltr">Hello Victor,<div><br></div><div>This list of iterators is a good place to look for examples:</div><div><br></div><div>  <a href="http://www.itk.org/Doxygen/html/group__ImageIterators.html">http://www.itk.org/Doxygen/html/group__ImageIterators.html</a></div><div><br></div><div>For instance, the itk::FloodFilledImageFunctionConditionalConstIterator may be of interest.</div><div><br></div><div>The image iterators do not have many virtual methods, but that should not discourage the creation of new classes -- the methods are not virtual because of performance reasons.</div><div><br></div><div>HTH,</div><div>Matt</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Dec 14, 2015 at 10:40 AM, Poughon Victor <span dir="ltr"><<a href="mailto:Victor.Poughon@cnes.fr" target="_blank">Victor.Poughon@cnes.fr</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><br>
Hello,<br>
<br>
I am trying to iterate over an image in a manner which depends on something only known at runtime. It seems like the iterator interface is not designed to handle this use case with polymorphism, because most methods are not virtual.<br>
<br>
I am thinking about writing that code into the iterator itself, but that's not so elegant because the iterator's code already has other responsibilities (iterating over the image in a specific way, etc.)<br>
<br>
Thanks for any help!<br>
<br>
Victor Poughon<br>
<br>
<br>
_____________________________________<br>
Powered by <a href="http://www.kitware.com" rel="noreferrer" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at<br>
<a href="http://www.kitware.com/opensource/opensource.html" rel="noreferrer" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
<br>
Kitware offers ITK Training Courses, for more information visit:<br>
<a href="http://www.kitware.com/products/protraining.php" rel="noreferrer" target="_blank">http://www.kitware.com/products/protraining.php</a><br>
<br>
Please keep messages on-topic and check the ITK FAQ at:<br>
<a href="http://www.itk.org/Wiki/ITK_FAQ" rel="noreferrer" target="_blank">http://www.itk.org/Wiki/ITK_FAQ</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://public.kitware.com/mailman/listinfo/insight-users" rel="noreferrer" target="_blank">http://public.kitware.com/mailman/listinfo/insight-users</a><br>
</blockquote></div><br></div>