<div>Hi, </div><div><br></div><div>MaskImageFilter is what you want. </div><div>You can set the outside value to </div><div>anything you want. Here is an example </div><div><br></div><a href="http://www.vtk.org/Wiki/ITK/Examples/ImageProcessing/MaskImageFilter">http://www.vtk.org/Wiki/ITK/Examples/ImageProcessing/MaskImageFilter</a><br>
<br>Cagatay<div><br><div class="gmail_quote">On Thu, Apr 19, 2012 at 12:37 AM, Hui Tang <span dir="ltr">&lt;<a href="mailto:tanghui.seu@gmail.com">tanghui.seu@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">
yes, use itkMultiplyImageFilter<div><a href="http://www.itk.org/Insight/Doxygen/html/classitk_1_1MultiplyImageFilter.html" target="_blank">http://www.itk.org/Insight/Doxygen/html/classitk_1_1MultiplyImageFilter.html</a> </div>
<div>sucess!<div><div class="h5"><br>
<br><div class="gmail_quote">On Wed, Apr 18, 2012 at 9:05 PM, Xiaopeng Yang <span dir="ltr">&lt;<a href="mailto:yxp233@postech.ac.kr" target="_blank">yxp233@postech.ac.kr</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">

<div lang="EN-US" link="blue" vlink="purple"><div><p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1f497d">Do you know how to multiply the mask with the original image? Is there any itk class to achieve this?<u></u><u></u></span></p>

<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1f497d"><u></u> <u></u></span></p><div style="border:none;border-top:solid #b5c4df 1.0pt;padding:3.0pt 0in 0in 0in">

<p class="MsoNormal"><b><span style="font-size:10.0pt;font-family:&quot;Tahoma&quot;,&quot;sans-serif&quot;">From:</span></b><span style="font-size:10.0pt;font-family:&quot;Tahoma&quot;,&quot;sans-serif&quot;"> Hui Tang [mailto:<a href="mailto:tanghui.seu@gmail.com" target="_blank">tanghui.seu@gmail.com</a>] <br>

<b>Sent:</b> Wednesday, April 18, 2012 11:34 PM<br><b>To:</b> Xiaopeng Yang<br><b>Cc:</b> <a href="mailto:insight-users@itk.org" target="_blank">insight-users@itk.org</a>; vtk<br><b>Subject:</b> Re: [Insight-users] Create an image<u></u><u></u></span></p>

</div><div><p class="MsoNormal"><u></u> <u></u></p><p class="MsoNormal">if your segmentation is partial volume, then threshould it at 0.5, if your segmentation is an signed distance map, threshould it at 0, the map should be 1 inside and o outside<u></u><u></u></p>

<div><p class="MsoNormal">then multiply your mask with the original image<u></u><u></u></p></div><p class="MsoNormal"><u></u> <u></u></p></div><div><div><p class="MsoNormal">On Wed, Apr 18, 2012 at 4:06 PM, Xiaopeng Yang &lt;<a href="mailto:yxp233@postech.ac.kr" target="_blank">yxp233@postech.ac.kr</a>&gt; wrote:<u></u><u></u></p>

</div><div><div><div><div><p class="MsoNormal">Dear Users,<u></u><u></u></p><p class="MsoNormal"> <u></u><u></u></p><p class="MsoNormal">I have two images, an original abdominal gray-scale CT image, and a segmented mask image of the liver from the CT image. I would like to create a new gray-scale image from the original CT image so that in the new image, the intensity value of the points outside the segmented liver is set to be 0, while the points within the segmented liver do not change. <u></u><u></u></p>

<p class="MsoNormal"> <u></u><u></u></p><p class="MsoNormal">I think there should be some example to do this. But I could not find any one from Google search. If you know any example, please share it with me.<u></u><u></u></p>

<p class="MsoNormal"> <u></u><u></u></p><p class="MsoNormal">Thank you,<u></u><u></u></p><p class="MsoNormal">Xiaopeng<u></u><u></u></p></div></div></div></div><p class="MsoNormal" style="margin-bottom:12.0pt"><br></p><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<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.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><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><u></u><u></u></div>

<p></p></div><p class="MsoNormal"><u></u> <u></u></p></div></div></blockquote></div><br></div></div></div>
<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.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>
<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></div>