<div dir="ltr"><div>Hi all,<br><br></div><div>I am trying to build an Inverter for Deformation Fields that I gathered from source code at:<br><br><a href="http://www.insight-journal.com/browse/publication/768">http://www.insight-journal.com/browse/publication/768</a><br>
<br></div><div>The error I&#39;m pasting below has something to do with using smartpointers, I believe, but if anyone can point to the change I need to make, I&#39;d be very appreciative. Thanks!<br></div><div><br></div><div>
I am getting the following error when compiling in Visual Studio Express 2010:<br><br>C:/ITKrap/InsightToolkit-4.2.0/Modules/Core/Common/include\itkFixedPointInverseDeformationFieldImageFilter.txx(109): error C2664: &#39;itk::ImageRegionIterator&lt;TImage&gt;::Set&#39; : cannot convert parameter 1 from &#39;itk::Vector&lt;T,NVectorDimension&gt;&#39; to &#39;const itk::Vector&lt;T,NVectorDimension&gt; &amp;&#39;<br>
          with<br>          [<br>              TImage=itk::Image&lt;VectorPixelType,3&gt;<br>          ]<br>          and<br>          [<br>              T=double,<br>              NVectorDimension=3<br>          ]<br>          and<br>
          [<br>              T=float,<br>              NVectorDimension=3<br>          ]<br>          Reason: cannot convert from &#39;itk::Vector&lt;T,NVectorDimension&gt;&#39; to &#39;const itk::Vector&lt;T,NVectorDimension&gt;&#39;<br>
          with<br>          [<br>              T=double,<br>              NVectorDimension=3<br>          ]<br>          and<br>          [<br>              T=float,<br>              NVectorDimension=3<br>          ]<br>          No user-defined-conversion operator available that can perform this conversion, or the operator cannot be called<br>
          C:/ITKrap/InsightToolkit-4.2.0/Modules/Core/Common/include\itkFixedPointInverseDeformationFieldImageFilter.txx(51) : while compiling class template member function &#39;void itk::FixedPointInverseDeformationFieldImageFilter&lt;TInputImage,TOutputImage&gt;::GenerateData(void)&#39;<br>
          with<br>          [<br>              TInputImage=InputDFType,<br>              TOutputImage=OutputDFType<br>          ]<br>          C:\ITKrap\DiffeomorphicDemons-2009-06-Vercauteren-IJSource\InvertDeformationField.cxx(50) : see reference to class template instantiation &#39;itk::FixedPointInverseDeformationFieldImageFilter&lt;TInputImage,TOutputImage&gt;&#39; being compiled<br>
          with<br>          [<br>              TInputImage=InputDFType,<br>              TOutputImage=OutputDFType<br>          ]<br clear="all"></div><div><br>-- <br>Tim Bhatnagar<br>PhD Candidate<br>Orthopaedic Injury Biomechanics Group<br>
Department of Mechanical Engineering<br>University of British Columbia<br><br>Rm 5000 - 818 West 10th Ave.<br>Vancouver, BC<br>Canada<br>V5Z 1M9<br><br>Ph: (604) 675-8845<br>Fax: (604) 675-8820<br>Web: <a href="http://oibg.mech.ubc.ca" target="_blank">oibg.mech.ubc.ca</a><br>
</div><br>
</div>