<html><head><style type='text/css'>p { margin: 0; }</style></head><body><div style='font-family: Times New Roman; font-size: 12pt; color: #000000'>When you don't have specific tools to do that (as proposed in the previous email), an easy and fast way to obtain the contour(s) of a mask image (denoted M) is the following:<br>Let D be the mask M dilated by one pixel. Then, the points on the contour are the pixel x where D(x)-M(x)=1.<br>It's not perfect but it's easy and it works everytime, whatever the programming language (ITK, Matlab, etc.).<br><br>Cheers,<br><br>Vincent Garcia<br><br><hr id="zwchr"><blockquote style="border-left:2px solid rgb(16, 16, 255);margin-left:5px;padding-left:5px;"><b>From: </b>"robert tamburo" <robert.tamburo@gmail.com><br><b>To: </b>"Quan" <mrvillage@163.com><br><b>Cc: </b>"insight-users" <insight-users@itk.org><br><b>Sent: </b>Saturday, 21 May, 2011 5:49:20 AM<br><b>Subject: </b>Re: [Insight-users] how to extract the contour in a binary image<br><br><a href="http://www.itk.org/Doxygen318/html/classitk_1_1BinaryContourImageFilter.html" target="_blank">http://www.itk.org/Doxygen318/html/classitk_1_1BinaryContourImageFilter.html</a><br><br><div class="gmail_quote">2011/5/20 Quan <span dir="ltr"><<a href="mailto:mrvillage@163.com" target="_blank">mrvillage@163.com</a>></span><br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;"><div>hello everyone:</div>
<div>i get a binary image ,the pixels==1 reprensent the foreground and pixels==0 represent background.Now i want to get the contour of the different regions.and i dont wanna use edge detectors like "LOG" or "Sobel".can anybody give me some advice?in addition,it seems that itk::ExtractImageFilter cannot do this task.</div>
<div>thanks</div>
<div>Quan</div><font color="#888888"><br><br><span title="neteasefooter"><span></span></span></font><br>_____________________________________<br>
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>
Kitware offers ITK Training Courses, for more information visit:<br>
<a href="http://www.kitware.com/products/protraining.html" target="_blank">http://www.kitware.com/products/protraining.html</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>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://www.itk.org/mailman/listinfo/insight-users" target="_blank">http://www.itk.org/mailman/listinfo/insight-users</a><br>
<br></blockquote></div><br>
<br>_____________________________________<br>Powered by www.kitware.com<br><br>Visit other Kitware open-source projects at<br>http://www.kitware.com/opensource/opensource.html<br><br>Kitware offers ITK Training Courses, for more information visit:<br>http://www.kitware.com/products/protraining.html<br><br>Please keep messages on-topic and check the ITK FAQ at:<br>http://www.itk.org/Wiki/ITK_FAQ<br><br>Follow this link to subscribe/unsubscribe:<br>http://www.itk.org/mailman/listinfo/insight-users<br></blockquote><br></div></body></html>