<html><head><style type="text/css"><!-- DIV {margin:0px;} --></style></head><body><div style="font-family:times new roman, new york, times, serif;font-size:12pt"><DIV>Hi;</DIV>
<DIV>I would like to write registration result to ths folder,I searched through the internet &nbsp;but I have not seen any example like that. Here is my code ,in fact I am not an expert of ITK So I want you to check following code for me. Is that true?I integrated that code to my project but I did not get any result. On the other hand When I compile it, compiler says no any error?</DIV>
<DIV>&nbsp;</DIV>
<DIV>Please Check that code for me;</DIV>
<DIV>&nbsp;</DIV>
<DIV><FONT size=2>
<P><FONT size=3>transform-&gt;SetParameters( finalParameters );</FONT></P>
<P><FONT size=3>&nbsp;</FONT></P>
<P><FONT size=3>TransformType::Pointer finalTransform = TransformType::New();</FONT></P>
<P><FONT size=3>finalTransform-&gt;SetParameters( finalParameters );</FONT></P>
<P></FONT><FONT color=#0000ff>typedef</FONT> <FONT color=#0000ff>unsigned</FONT> <FONT color=#0000ff>short</FONT> OutputPixelType;</P><FONT color=#008000>
<P>// typedef itk::Image&lt; MovingImageType, Dimension &gt; MovingImageType;</P></FONT>
<P><FONT color=#0000ff>typedef</FONT> itk::Image&lt; OutputPixelType, Dimension &gt; OutputImageType;</P>
<P></P>
<P><FONT color=#0000ff>typedef</FONT> itk::ResampleImageFilter&lt;MovingImageType,OutputImageType&gt; FilterType;</P>
<P>FilterType::Pointer resample = FilterType::New();</P>
<P>resample-&gt;SetTransform( finalTransform );</P>
<P>resample-&gt;SetInput( input );</P>
<P></P>
<P><FONT color=#008000>// defining spacing, origin and size (The parameters of the output image are taken from the input image.)</P></FONT>
<P><FONT color=#0000ff>const</FONT> MovingImageType::SpacingType&amp;</P>
<P>spacing = input-&gt;GetSpacing();</P>
<P><FONT color=#0000ff>const</FONT> MovingImageType::PointType&amp;</P>
<P>origin = input-&gt;GetOrigin();</P>
<P>MovingImageType::SizeType size = </P>
<P>input-&gt;GetLargestPossibleRegion().GetSize();</P>
<P>resample-&gt;SetOutputOrigin( origin );</P>
<P>resample-&gt;SetOutputSpacing( spacing );</P>
<P>resample-&gt;SetSize( size );</P>
<P><FONT color=#0000ff>typedef</FONT> itk::Image&lt; OutputPixelType, Dimension &gt; OutputImageType; </P>
<P><FONT color=#0000ff>typedef</FONT> itk::ImageFileWriter&lt; OutputImageType &gt; WriterType;</P>
<P>WriterType::Pointer writer = WriterType::New();</P>
<P>writer-&gt;SetFileName(<FONT color=#800000>"result_of_registration.mhd"</FONT><FONT size=2><FONT size=3>); // <FONT color=#ff0000>Here I set the file name</FONT></FONT></P>
<P><FONT size=3>writer-&gt;SetInput( resample-&gt;GetOutput());</FONT></P>
<P><FONT size=3>writer-&gt;Update();</FONT></P></FONT></DIV></div><br>

<hr size=1>Be a PS3 game guru.<br>Get your game face on with <a href="http://us.rd.yahoo.com/evt=49936/*http://videogames.yahoo.com">the latest PS3 news and previews at Yahoo! Games.</a></body></html>