diff --git a/modules/photo/src/contrast_preserve.cpp b/modules/photo/src/contrast_preserve.cpp index 103322a1b2..9c7227405d 100644 --- a/modules/photo/src/contrast_preserve.cpp +++ b/modules/photo/src/contrast_preserve.cpp @@ -55,7 +55,7 @@ double norm_m(double); double norm_m(double E) { - return sqroot(power(E,2)); + return sqrt(power(E,2)); } void cv::decolor(InputArray _src, OutputArray _dst, OutputArray _color_boost) diff --git a/modules/photo/src/contrast_preserve.hpp b/modules/photo/src/contrast_preserve.hpp index eff1530df5..587e431e08 100644 --- a/modules/photo/src/contrast_preserve.hpp +++ b/modules/photo/src/contrast_preserve.hpp @@ -235,7 +235,7 @@ void Decolor::colorGrad(Mat img, vector &Cg) double res =0.0; for(unsigned int i=0;i(i,j*channel+c) = - sqrt(pow(srx32.at(i,j*channel+c),2) + pow(sry32.at(i,j*channel+c),2)); + sqrt(power(srx32.at(i,j*channel+c),2) + power(sry32.at(i,j*channel+c),2)); } for(int i=0;i < h; i++) @@ -738,9 +750,9 @@ void Cloning::illum_change(Mat &I, Mat &mask, Mat &wmask, Mat &final, float alph if(srx32.at(i,j*channel+c) != 0) { srx32.at(i,j*channel+c) = - pow(alpha,beta)*srx32.at(i,j*channel+c)*pow(mag.at(i,j*channel+c),-1*beta); + power(alpha,beta)*srx32.at(i,j*channel+c)*power(mag.at(i,j*channel+c),-1*beta); sry32.at(i,j*channel+c) = - pow(alpha,beta)*sry32.at(i,j*channel+c)*pow(mag.at(i,j*channel+c),-1*beta); + power(alpha,beta)*sry32.at(i,j*channel+c)*power(mag.at(i,j*channel+c),-1*beta); } }