<div dir="ltr">Hi Massi,<div><br></div><div>Could you please share your definition of &quot;ImageType&quot; ?</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">&lt;<a href="mailto:Massinissa.Bandou@usherbrooke.ca" target="_blank">Massinissa.Bandou@usherbrooke.ca</a>&gt;</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&lt;double&gt; Rigid2DTransformType;<br>
        typedef<br>
itk::LandmarkBasedTransformInitializer&lt;Rigid2DTransformType,ImageType,ImageType&gt;<br>
LandmarkBasedTransformInitializerType;<br>
        Rigid2DTransformType::Pointer transform =<br>
Rigid2DTransformType::New();<br>
<br>
        transform-&gt;SetIdentity();<br>
        landmarkBasedTransformInitializer-&gt;SetTransform(transform);<br>
        landmarkBasedTransformInitializer-&gt;InitializeTransform();<br>
<br>
        typedef itk::ResampleImageFilter&lt;ImageType, ImageType, double &gt;<br>
ResampleFilterType;<br>
        ResampleFilterType::Pointer resampleFilter = ResampleFilterType::New();<br>
        resampleFilter-&gt;SetInput(movingImage);<br>
        resampleFilter-&gt;SetTransform(transform.GetPointer());<br>
<br>
<br>
I ll get this error:<br>
Error   5       error C2664:<br>
<div class="im">&#39;itk::ResampleImageFilter&lt;TInputImage,TOutputImage&gt;::SetTransform&#39; : cannot<br>
</div>convert parameter 1 from &#39;itk::Rigid2DTransform&lt;TScalarType&gt; *&#39; to &#39;const<br>
<div class="im">itk::Transform&lt;TScalarType,NInputDimensions,NOutputDimensions&gt; *&#39;<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>