diff --git a/Code/FeatureExtraction/otbFlusserImageFunction.h b/Code/FeatureExtraction/otbFlusserImageFunction.h index 809217b6a591057791ec544ed87022f278f14f5f..f791f7c0985925bcc53465ef8bc5679ff6af1576 100644 --- a/Code/FeatureExtraction/otbFlusserImageFunction.h +++ b/Code/FeatureExtraction/otbFlusserImageFunction.h @@ -69,11 +69,11 @@ public: /** Standard class typedefs. */ typedef FlusserImageFunction Self; typedef itk::ImageFunction< TInputImage, - itk::FixedArray< - ITK_TYPENAME itk::NumericTraits< - typename TInputImage::PixelType>::RealType, - 11 >, - TCoordRep > Superclass; + itk::FixedArray< + ITK_TYPENAME itk::NumericTraits< + typename TInputImage::PixelType>::RealType, + 11 >, + TCoordRep > Superclass; typedef itk::SmartPointer<Self> Pointer; typedef itk::SmartPointer<const Self> ConstPointer; diff --git a/Code/FeatureExtraction/otbFlusserImageFunction.txx b/Code/FeatureExtraction/otbFlusserImageFunction.txx index 4f086974ce247dfdd8891214fc5c320fc08463c5..e4cf5afb87e446d80e7cbfd56c1e7bfee763cc56 100644 --- a/Code/FeatureExtraction/otbFlusserImageFunction.txx +++ b/Code/FeatureExtraction/otbFlusserImageFunction.txx @@ -108,26 +108,26 @@ FlusserImageFunction<TInputImage,TCoordRep> ComplexType xpy(x,y),xqy(x,-y); // Update cumulants - c00+=value; - c11+=xpy*xqy*value; - c12+=xpy*xqy*xqy*value; - c21+=xpy*xpy*xqy*value; - c20+=xpy*xpy*value; - c30+=xpy*xpy*xpy*value; - c22+=xpy*xpy*xqy*xqy*value; - c31+=xpy*xpy*xpy*xqy*value; - c40+=xpy*xpy*xpy*xpy*value; + c00 += value; + c11 += xpy*xqy*value; + c12 += xpy*xqy*xqy*value; + c21 += xpy*xpy*xqy*value; + c20 += xpy*xpy*value; + c30 += xpy*xpy*xpy*value; + c22 += xpy*xpy*xqy*xqy*value; + c31 += xpy*xpy*xpy*xqy*value; + c40 += xpy*xpy*xpy*xpy*value; } // Nomalisation - c11/=vcl_pow(c00, (1+1)/2); - c12/=vcl_pow(c00, (1+2)/2); - c21/=vcl_pow(c00, (2+1)/2); - c20/=vcl_pow(c00, (2+0)/2); - c30/=vcl_pow(c00, (3+0)/2); - c22/=vcl_pow(c00, (2+2)/2); - c31/=vcl_pow(c00, (3+1)/2); - c40/=vcl_pow(c00, (4+0)/2); + c11 /= vcl_pow(c00, (1+1)/2); + c12 /= vcl_pow(c00, (1+2)/2); + c21 /= vcl_pow(c00, (2+1)/2); + c20 /= vcl_pow(c00, (2+0)/2); + c30 /= vcl_pow(c00, (3+0)/2); + c22 /= vcl_pow(c00, (2+2)/2); + c31 /= vcl_pow(c00, (3+1)/2); + c40 /= vcl_pow(c00, (4+0)/2); // Compute moments combinations moments[0] = static_cast<ScalarRealType>(c11.real()); @@ -149,4 +149,3 @@ FlusserImageFunction<TInputImage,TCoordRep> } // namespace otb #endif - diff --git a/Code/FeatureExtraction/otbHuImageFunction.h b/Code/FeatureExtraction/otbHuImageFunction.h index 483f61cc84bbb91d68b4fd46aeae37d5343be008..7d75db1382669933b7c6f184b760f543b8b4c02b 100644 --- a/Code/FeatureExtraction/otbHuImageFunction.h +++ b/Code/FeatureExtraction/otbHuImageFunction.h @@ -65,11 +65,11 @@ public: /** Standard class typedefs. */ typedef HuImageFunction Self; typedef itk::ImageFunction< TInputImage, - itk::FixedArray< - ITK_TYPENAME itk::NumericTraits< + itk::FixedArray< + ITK_TYPENAME itk::NumericTraits< typename TInputImage::PixelType>::RealType, - 7 >, - TCoordRep > Superclass; + 7 >, + TCoordRep > Superclass; typedef itk::SmartPointer<Self> Pointer; typedef itk::SmartPointer<const Self> ConstPointer; diff --git a/Code/FeatureExtraction/otbHuImageFunction.txx b/Code/FeatureExtraction/otbHuImageFunction.txx index 461b617f6be5f7aa5d0065159a8eb5ed04164a9e..645dc36280483b67cb66541a6eb8548640904075 100644 --- a/Code/FeatureExtraction/otbHuImageFunction.txx +++ b/Code/FeatureExtraction/otbHuImageFunction.txx @@ -107,24 +107,24 @@ HuImageFunction<TInputImage, TCoordRep> ComplexType xpy(x,y),xqy(x,-y); // Update cumulants - c00+=value; - c11+=xpy*xqy*value; - c20+=xpy*xpy*value; - c02+=xqy*xqy*value; - c30+=xpy*xpy*xpy*value; - c03+=xqy*xqy*xqy*value; - c21+=xpy*xpy*xqy*value; - c12+=xpy*xqy*xqy*value; + c00 += value; + c11 += xpy*xqy*value; + c20 += xpy*xpy*value; + c02 += xqy*xqy*value; + c30 += xpy*xpy*xpy*value; + c03 += xqy*xqy*xqy*value; + c21 += xpy*xpy*xqy*value; + c12 += xpy*xqy*xqy*value; } // Nomalisation - c11/=vcl_pow(c00, (1+1)/2); - c20/=vcl_pow(c00, (2+0)/2); - c02/=vcl_pow(c00, (0+2)/2); - c30/=vcl_pow(c00, (3+0)/2); - c03/=vcl_pow(c00, (0+3)/2); - c21/=vcl_pow(c00, (2+1)/2); - c12/=vcl_pow(c00, (1+2)/2); + c11 /= vcl_pow(c00, (1+1)/2); + c20 /= vcl_pow(c00, (2+0)/2); + c02 /= vcl_pow(c00, (0+2)/2); + c30 /= vcl_pow(c00, (3+0)/2); + c03 /= vcl_pow(c00, (0+3)/2); + c21 /= vcl_pow(c00, (2+1)/2); + c12 /= vcl_pow(c00, (1+2)/2); // Compute moments combinations moments[0] = static_cast<ScalarRealType>(c11.real());