<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=gb2312">
<META content="MSHTML 6.00.2900.2912" name=GENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=#ffffff>
<DIV><FONT face="Bookman Old Style">Hi,</FONT></DIV>
<DIV><FONT face="Bookman Old Style"></FONT> </DIV>
<DIV><FONT face="Bookman Old Style">The fixedImage and the movingImage have the
same spacing, origin, and size. Both are 256 x 256 x 48. I use the grid with
size 256 x 256 x 1 and start index (0,0,24) as the resample grid. I do
as below,</FONT></DIV>
<DIV><FONT face="Bookman Old Style"></FONT> </DIV>
<DIV><FONT face="Bookman Old Style">typedef itk::Image<short, 3>
ImageType;</FONT></DIV>
<DIV><FONT face="Bookman Old Style">typedef
itk::ResampleImageFilter<ImageType, ImageType>
ResampleFilterType;</FONT></DIV>
<DIV><FONT face="Bookman Old Style">ResampleFilterType::Pointer resampler =
ResampleFilterType::New();</FONT></DIV>
<DIV><FONT face="Bookman Old Style"></FONT> </DIV>
<DIV><FONT face="Bookman Old Style"> resampler->SetTransform( transform
);<BR>// resampler->SetInterpolator(this->interpolator);<BR> resampler->SetInput( movingImage
);<BR> size =
fixedImage->GetLargestPossibleRegion().GetSize();<BR> size[2] =
1;<BR> index[2] = 24;<BR> index[0] = index[1] =
0;<BR> this->resampler->SetSize(size);<BR> this->resampler->SetOutputStartIndex(index);<BR> this->resampler->SetOutputOrigin(
fixedImage->GetOrigin() );<BR> this->resampler->SetOutputSpacing(
fixedImage->GetSpacing()
);<BR> this->resampler->SetDefaultPixelValue( 100
);<BR> this->resampler->Update();</FONT></DIV>
<DIV><FONT face="Bookman Old Style"></FONT> </DIV>
<DIV><FONT face="Bookman Old Style">I use a identity transform. However, when I
show the resampled image, it roate 90 degree relative to the correct position. I
am confused about it.</FONT></DIV>
<DIV><FONT face="Bookman Old Style"></FONT> </DIV>
<DIV><FONT face="Bookman Old Style">Regards,</FONT></DIV>
<DIV><FONT face="Bookman Old Style"></FONT> </DIV>
<DIV><FONT face="Bookman Old Style">Yixun Liu</DIV>
<DIV><BR></DIV></FONT>
<DIV><FONT face="Bookman Old Style"></FONT> </DIV></BODY></HTML>