From: Vivien Delmon Date: Wed, 21 Aug 2013 09:54:40 +0000 (+0200) Subject: Use IsNormal instead of std::isnormal (C++11) X-Git-Tag: v1.4.0~164^2 X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=commitdiff_plain;h=25a348e28347eb17421e59c655716cbb29254d19;p=clitk.git Use IsNormal instead of std::isnormal (C++11) std::isnormal is a C++11 function not available in VS 2012 use IsNormal defined in clitkPortability instead --- diff --git a/tools/clitkImageUncertainty.cxx b/tools/clitkImageUncertainty.cxx index bf5759f..63b1f12 100644 --- a/tools/clitkImageUncertainty.cxx +++ b/tools/clitkImageUncertainty.cxx @@ -34,13 +34,12 @@ #include "clitkImageUncertainty_ggo.h" #include "clitkImageCommon.h" #include "clitkCommon.h" +#include "clitkPortability.h" // itk include #include "itkImageRegionConstIterator.h" #include "itkImageRegionIterator.h" -#include // for isfinite - //==================================================================== int main(int argc, char * argv[]) { @@ -79,7 +78,7 @@ int main(int argc, char * argv[]) { double squared = pii.Get(); double mean = pi.Get(); double uncert = sqrt((NumberOfEvents*squared - mean*mean) / ((NumberOfEvents-1)*(mean*mean))); - if (!std::isnormal(uncert)) uncert = 1.; + if (!IsNormal(uncert)) uncert = 1.; po.Set(uncert); ++pi; ++pii;