[Insight-users] ITKRegionGrowingPython and ITKDistanceMapPython Compile Errors on MSVS2008 to x64
Constantine Zakkaroff
mnkz at leeds.ac.uk
Thu Aug 16 06:29:53 EDT 2012
Hello ALL,
When compiling ITK 4.2 with Python wrapping on MSVS2008 to x64 I get the
following errors which come up during explicit instantiation with float:
Error 168 error C2665: 'itk::NumericTraits<T>::ZeroValue' : none of the
2 overloads could convert all the argument types
e:\temp\insighttoolkit-4.2.0\modules\core\imagefunction\include\itkVectorMeanImageFunction.hxx
90 ITKRegionGrowingPython
Error 169 error C2665: 'itk::NumericTraits<T>::GetLength' : none of the
2 overloads could convert all the argument types
e:\temp\insighttoolkit-4.2.0\modules\core\imagefunction\include\itkVectorMeanImageFunction.hxx
99 ITKRegionGrowingPython
And these errors come up during explicit instantiation with short,
because fabs on MSVS doesn't cope with short:
Error 174 error C2668: 'fabs' : ambiguous call to overloaded function
e:\temp\insighttoolkit-4.2.0\modules\filtering\distancemap\include\itkIsoContourDistanceImageFilter.hxx
383 ITKDistanceMapPython
Error 175 error C2668: 'fabs' : ambiguous call to overloaded function
e:\temp\insighttoolkit-4.2.0\modules\filtering\distancemap\include\itkIsoContourDistanceImageFilter.hxx
387 ITKDistanceMapPython
Here's what MSVS2008 says about short passed to fabs:
618> c:\Program Files (x86)\Microsoft Visual Studio
9.0\VC\include\math.h(119): could be 'double fabs(double)'
618> c:\Program Files (x86)\Microsoft Visual Studio
9.0\VC\include\math.h(509): or 'float fabs(float)'
618> c:\Program Files (x86)\Microsoft Visual Studio
9.0\VC\include\math.h(557): or 'long double fabs(long double)'
618> while trying to match the argument list '(short)'
I can see how to correct the errors on my machine, or instead I can try
out patches if any are suggested.
Regards,
Constantine
Many thanks,
Constantine
More information about the Insight-users
mailing list