<div dir="ltr">Hi Massi,<div><br></div><div>Could you please share your definition of "ImageType" ?</div><div><br></div><div>There seems to be a mismatch between the dimensions of the image type and the dimension of the transform type.</div>
<div><br></div><div>   Thanks</div><div><br></div><div>        Luis</div><div><br></div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Wed, Dec 11, 2013 at 2:45 PM, Massinissa Bandou <span dir="ltr"><<a href="mailto:Massinissa.Bandou@usherbrooke.ca" target="_blank">Massinissa.Bandou@usherbrooke.ca</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Thanks for the quick reply Hans<br>
If I get the pointer from  transform:<br>
<br>
        typedef itk::Rigid2DTransform<double> Rigid2DTransformType;<br>
        typedef<br>
itk::LandmarkBasedTransformInitializer<Rigid2DTransformType,ImageType,ImageType><br>
LandmarkBasedTransformInitializerType;<br>
        Rigid2DTransformType::Pointer transform =<br>
Rigid2DTransformType::New();<br>
<br>
        transform->SetIdentity();<br>
        landmarkBasedTransformInitializer->SetTransform(transform);<br>
        landmarkBasedTransformInitializer->InitializeTransform();<br>
<br>
        typedef itk::ResampleImageFilter<ImageType, ImageType, double ><br>
ResampleFilterType;<br>
        ResampleFilterType::Pointer resampleFilter = ResampleFilterType::New();<br>
        resampleFilter->SetInput(movingImage);<br>
        resampleFilter->SetTransform(transform.GetPointer());<br>
<br>
<br>
I ll get this error:<br>
Error   5       error C2664:<br>
<div class="im">'itk::ResampleImageFilter<TInputImage,TOutputImage>::SetTransform' : cannot<br>
</div>convert parameter 1 from 'itk::Rigid2DTransform<TScalarType> *' to 'const<br>
<div class="im">itk::Transform<TScalarType,NInputDimensions,NOutputDimensions> *'<br>
C:\Users\Massi\Desktop\TomoRegistration\TomoRegistration\ITKRegistration.cpp<br>
319     1       TomoRegistration<br>
<br>
<br>
<br>
<br>
</div>--<br>
View this message in context: <a href="http://itk-users.7.n7.nabble.com/LandmarkBasedTransformInitializer-tp32954p32956.html" target="_blank">http://itk-users.7.n7.nabble.com/LandmarkBasedTransformInitializer-tp32954p32956.html</a><br>

<div class="HOEnZb"><div class="h5">Sent from the ITK - Users mailing list archive at Nabble.com.<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>
</div></div></blockquote></div><br></div>