<div>Thanks Luis. This is very helpful.</div>
<div> </div>
<div>A question that I didn't find explained in the chapters. How is the 8-bit char data type in ImageMaskType interpreted as binary? Also, is 1 or 0 pixel location being masked out?</div>
<div> </div>
<div>Thanks.</div>
<div> </div>
<div>Regards,</div>
<div>Brandon<br><br> </div>
<div><span class="gmail_quote">On 5/21/08, <b class="gmail_sendername">Luis Ibanez</b> <<a href="mailto:luis.ibanez@kitware.com">luis.ibanez@kitware.com</a>> wrote:</span>
<blockquote class="gmail_quote" style="PADDING-LEFT: 1ex; MARGIN: 0px 0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid"><br><br>Hi Brandon,<br><br><br> Yes,<br> You can use non-rectangular masks in the registration framework.<br>
<br><br><br>This is done by passing to the RegistrationMethod object masks defined<br>by SpatialObjects. You can pass one mask that sits on the Fixed image<br>coordinate system, and another mask that sits in the Moving image one.<br>
<br><br>For an example of how to do this, you can read the ITK Software Guide<br><br> <a onclick="return top.js.OpenExtLink(window,event,this)" href="http://www.itk.org/ItkSoftwareGuide.pdf" target="_blank">http://www.itk.org/ItkSoftwareGuide.pdf</a><br>
<br>In particular,<br><br> section 8.10 "Metrics" in pdf-page 447.<br><br>and also,<br><br> section 8.11.3, "Registration using masks constructed<br> with Spatial Objects", in pdf-page 464.<br>
<br><br>You will find a source code example in<br><br> Insight/Examples/Registration/ImageRegistration12.cxx<br><br><br> Regards,<br><br><br> Luis<br><br><br><br>--------------------<br>Brandon Lin wrote:<br>
<blockquote class="gmail_quote" style="PADDING-LEFT: 1ex; MARGIN: 0px 0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid"><span class="q">Is there a way to create a non-rectangular shaped region? Or is there a way to perform registration with some pixel locations masked out? I would like perform registration between two images, but there are some pixels at the top left and top right corners I need to mask out. If I use rectangular region, I will have to give up columns or rows of pixels, which is not preferred. Any thoughts or feedback are appreciated. Thanks.<br>
Regards,<br>Brandon<br><br><br></span><span class="q"> On 3/31/08, *Brandon Lin* <<a onclick="return top.js.OpenExtLink(window,event,this)" href="mailto:brandon.lin@gmail.com" target="_blank">brandon.lin@gmail.com</a> <mailto:<a onclick="return top.js.OpenExtLink(window,event,this)" href="mailto:brandon.lin@gmail.com" target="_blank">brandon.lin@gmail.com</a>>> wrote:<br>
<br> Thank Tomáš.<br> Brandon<br><br> On 3/31/08, *Tomáš Kazmar* <<a onclick="return top.js.OpenExtLink(window,event,this)" href="mailto:Tomash.Kazmar@seznam.cz" target="_blank">Tomash.Kazmar@seznam.cz</a><br>
</span>
<div><span class="e" id="q_11a0b8d35a193837_3"> <mailto:<a onclick="return top.js.OpenExtLink(window,event,this)" href="mailto:Tomash.Kazmar@seznam.cz" target="_blank">Tomash.Kazmar@seznam.cz</a>>> wrote:<br><br>
Hi Brandon,<br><br> just do what you describe. Create a region of your image's<br> region type, setup<br> its index and size, and call SetFixedImageRegion():<br><br> ImageType::RegionType region;<br>
ImageType::IndexType index;<br> ImageType::SizeType size;<br> for (int i = 0; i < ImageType::ImageDimension; i++) {<br> index[i] = ...start of your region...<br> size[i] = ...size of your region...<br>
}<br> region.SetIndex(index);<br> region.SetSize(size);<br> ...<br> registration.SetFixedImageRegion(region);<br><br> For more information read the ITK Software Guide, Section 4.1 on<br>
Images.<br><br> Regards,<br> Tomas<br><br> # I'm trying to perform 2D image to image<br> registration. However, I'd like to<br> # define a region of the image to perform registration. I<br>
understand that<br> # this can be done using registration->SetFixedImageRegion()<br> method. The<br> # example only uses the full image. Could anyone please point me to<br> # documentation on how to setup the region? All I need to<br>
specify is the<br> # start pixel and length for each dimension.<br><br><br><br><br></span></div>------------------------------------------------------------------------<br><br>_______________________________________________<br>
Insight-users mailing list<br><a onclick="return top.js.OpenExtLink(window,event,this)" href="mailto:Insight-users@itk.org" target="_blank">Insight-users@itk.org</a><br><a onclick="return top.js.OpenExtLink(window,event,this)" href="http://www.itk.org/mailman/listinfo/insight-users" target="_blank">http://www.itk.org/mailman/listinfo/insight-users</a><br>
</blockquote></blockquote></div><br>