<font><font face="verdana,sans-serif">You should do an XOR of image with the mask and you will get regular binary image which you can supply to marching cubes.</font></font><div class="gmail_extra"><br><br><div class="gmail_quote">

On Fri, Nov 9, 2012 at 3:00 PM, wydesenej <span dir="ltr">&lt;<a href="mailto:wydesenej@gmail.com" target="_blank">wydesenej@gmail.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">

<div class="im">Hi.<br>
<br>
I have very specific image to describe structures in other image.<br>
Scalar value of each pixel consits of N-bits.<br>
Each bit represents some structure in image.<br>
<br>
Some examples:<br>
Pixel value = 11010000 -&gt; means that this pixel is in stuctures 1, 2 and 4<br>
Pixel value = 01010000 -&gt; means that this pixel is in stuctures 2 and 4<br>
Pixel value = 00001000 -&gt; means that this pixel is in stucture 5<br>
Pixel value = 00000000 -&gt; means that this pixel is not in any structure<br>
etc..<br>
<br>
Now I need to find contours of these structures.<br>
</div>I need to use some contour filter. Problem is that filters uses as input<br>
<div class="im">scalar value for contour but i want to set &quot;mask value&quot;.<br>
<br>
Example what i need:<br>
<br>
</div>someFilter filter;<br>
<div class="im">filter-&gt;SetInput( mySpecialBinaryImage );<br>
filter-&gt;SetValueMask( 00100000 );    -&gt; This function is not presented in<br>
filter. I want that this means: contour for me structure num3 ie. contour<br>
pixels with bit3 == 1.<br>
filter-&gt;Update();<br>
filter-&gt;GetOutput(); -&gt; There i get my countour. (if image is 2d i got<br>
polygon if 3d i got surface...)<br>
<br>
Please any ideas how to do this stuff?<br>
<br>
<br>
<br>
<br>
--<br>
</div>View this message in context: <a href="http://itk-insight-users.2283740.n2.nabble.com/Contour-generation-based-on-binary-images-tp7581588.html" target="_blank">http://itk-insight-users.2283740.n2.nabble.com/Contour-generation-based-on-binary-images-tp7581588.html</a><br>


Sent from the ITK Insight Users mailing list archive at Nabble.com.<br>
_____________________________________<br>
<div class="im">Powered by <a href="http://www.kitware.com" 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" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
<br>
</div>Kitware offers ITK Training Courses, for more information visit:<br>
<a href="http://www.kitware.com/products/protraining.php" 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" target="_blank">http://www.itk.org/Wiki/ITK_FAQ</a><br>
<div class="im"><br>
Follow this link to subscribe/unsubscribe:<br>
</div><a href="http://www.itk.org/mailman/listinfo/insight-users" target="_blank">http://www.itk.org/mailman/listinfo/insight-users</a><br>
</blockquote></div><br></div>