fixed (IppiSize&)sz
This commit is contained in:
@@ -487,10 +487,10 @@ void cv::accumulateSquare( InputArray _src, InputOutputArray _dst, InputArray _m
|
||||
int srcstep = (int)src.step, dststep = (int)dst.step, maskstep = (int)mask.step;
|
||||
if (src.isContinuous() && dst.isContinuous() && mask.isContinuous())
|
||||
{
|
||||
srcstep = src.total() * src.elemSize();
|
||||
dststep = dst.total() * dst.elemSize();
|
||||
maskstep = mask.total() * mask.elemSize();
|
||||
size.width = (int)src.total();
|
||||
srcstep = static_cast<int>(src.total() * src.elemSize());
|
||||
dststep = static_cast<int>(dst.total() * dst.elemSize());
|
||||
maskstep = static_cast<int>(mask.total() * mask.elemSize());
|
||||
size.width = static_cast<int>(src.total());
|
||||
size.height = 1;
|
||||
}
|
||||
size.width *= scn;
|
||||
@@ -564,13 +564,13 @@ void cv::accumulateProduct( InputArray _src1, InputArray _src2,
|
||||
|
||||
Size size = src1.size();
|
||||
int src1step = (int)src1.step, src2step = (int)src2.step, dststep = (int)dst.step, maskstep = (int)mask.step;
|
||||
if (src1.isContinuous() && src2.isContinuous() && dst.isContinuous() && mask.empty())
|
||||
if (src1.isContinuous() && src2.isContinuous() && dst.isContinuous() && mask.isContinuous())
|
||||
{
|
||||
src1step = src1.total() * src1.elemSize();
|
||||
src2step = src2.total() * src2.elemSize();
|
||||
dststep = dst.total() * dst.elemSize();
|
||||
maskstep = mask.total() * mask.elemSize();
|
||||
size.width = (int)src1.total();
|
||||
src1step = static_cast<int>(src1.total() * src1.elemSize());
|
||||
src2step = static_cast<int>(src2.total() * src2.elemSize());
|
||||
dststep = static_cast<int>(dst.total() * dst.elemSize());
|
||||
maskstep = static_cast<int>(mask.total() * mask.elemSize());
|
||||
size.width = static_cast<int>(src1.total());
|
||||
size.height = 1;
|
||||
}
|
||||
size.width *= scn;
|
||||
@@ -645,12 +645,12 @@ void cv::accumulateWeighted( InputArray _src, InputOutputArray _dst,
|
||||
|
||||
Size size = src.size();
|
||||
int srcstep = (int)src.step, dststep = (int)dst.step, maskstep = (int)mask.step;
|
||||
if (src.isContinuous() && dst.isContinuous() && mask.empty())
|
||||
if (src.isContinuous() && dst.isContinuous() && mask.isContinuous())
|
||||
{
|
||||
srcstep = src.total() * src.elemSize();
|
||||
dststep = dst.total() * dst.elemSize();
|
||||
maskstep = mask.total() * mask.elemSize();
|
||||
size.width = (int)src.total();
|
||||
srcstep = static_cast<int>(src.total() * src.elemSize());
|
||||
dststep = static_cast<int>(dst.total() * dst.elemSize());
|
||||
maskstep = static_cast<int>(mask.total() * mask.elemSize());
|
||||
size.width = static_cast<int>((int)src.total());
|
||||
size.height = 1;
|
||||
}
|
||||
size.width *= scn;
|
||||
|
@@ -3254,11 +3254,7 @@ void cv::cvtColor( InputArray _src, OutputArray _dst, int code, int dcn )
|
||||
if( CvtColorIPPLoopCopy(src, dst, IPPReorderFunctor(ippiSwapChannelsC3RTab[depth], 2, 1, 0)) )
|
||||
return;
|
||||
}
|
||||
<<<<<<< HEAD
|
||||
#if (IPP_VERSION_X100 >= 801)
|
||||
=======
|
||||
#if IPP_VERSION_MAJOR * 10 + IPP_VERSION_MINOR >= 81
|
||||
>>>>>>> cv::scaleAdd
|
||||
else if( code == CV_RGBA2BGRA )
|
||||
{
|
||||
if( CvtColorIPPLoopCopy(src, dst, IPPReorderFunctor(ippiSwapChannelsC4RTab[depth], 2, 1, 0)) )
|
||||
|
@@ -61,7 +61,7 @@ namespace cv
|
||||
typedef IppStatus (CV_STDCALL* ippiResizeGetSrcOffset)(void*, IppiPoint, IppiPoint*);
|
||||
#endif
|
||||
|
||||
#if defined (HAVE_IPP) && (IPP_VERSION_MAJOR >= 7)
|
||||
#if defined (HAVE_IPP) && (IPP_VERSION_MAJOR >= 7) && 0
|
||||
typedef IppStatus (CV_STDCALL* ippiSetFunc)(const void*, void *, int, IppiSize);
|
||||
typedef IppStatus (CV_STDCALL* ippiWarpPerspectiveFunc)(const void*, IppiSize, int, IppiRect, void *, int, IppiRect, double [3][3], int);
|
||||
typedef IppStatus (CV_STDCALL* ippiWarpAffineBackFunc)(const void*, IppiSize, int, IppiRect, void *, int, IppiRect, double [2][3], int);
|
||||
@@ -4015,7 +4015,7 @@ private:
|
||||
|
||||
|
||||
/*
|
||||
#if defined (HAVE_IPP) && IPP_VERSION_MAJOR * 10 + IPP_VERSION_MINOR >= 81
|
||||
#if defined (HAVE_IPP) && IPP_VERSION_MAJOR * 100 + IPP_VERSION_MINOR >= 801
|
||||
class IPPWarpAffineInvoker :
|
||||
public ParallelLoopBody
|
||||
{
|
||||
@@ -4215,7 +4215,7 @@ void cv::warpAffine( InputArray _src, OutputArray _dst,
|
||||
const int AB_SCALE = 1 << AB_BITS;
|
||||
|
||||
/*
|
||||
#if defined (HAVE_IPP) && IPP_VERSION_MAJOR * 10 + IPP_VERSION_MINOR >= 81
|
||||
#if defined (HAVE_IPP) && IPP_VERSION_MAJOR * 100 + IPP_VERSION_MINOR >= 801
|
||||
int type = src.type(), depth = CV_MAT_DEPTH(type), cn = CV_MAT_CN(type);
|
||||
if( ( depth == CV_8U || depth == CV_16U || depth == CV_32F ) &&
|
||||
( cn == 1 || cn == 3 || cn == 4 ) &&
|
||||
@@ -4381,53 +4381,52 @@ private:
|
||||
};
|
||||
|
||||
/*
|
||||
#if defined (HAVE_IPP) && IPP_VERSION_MAJOR * 10 + IPP_VERSION_MINOR >= 81
|
||||
#if defined (HAVE_IPP) && IPP_VERSION_MAJOR * 100 + IPP_VERSION_MINOR >= 801
|
||||
class IPPWarpPerspectiveInvoker :
|
||||
public ParallelLoopBody
|
||||
public ParallelLoopBody
|
||||
{
|
||||
public:
|
||||
IPPWarpPerspectiveInvoker(Mat &_src, Mat &_dst, double (&_coeffs)[3][3], int &_interpolation,
|
||||
int &_borderType, const Scalar &_borderValue, ippiWarpPerspectiveFunc _func, bool *_ok) :
|
||||
ParallelLoopBody(), src(_src), dst(_dst), mode(_interpolation), coeffs(_coeffs),
|
||||
borderType(_borderType), borderValue(_borderValue), func(_func), ok(_ok)
|
||||
{
|
||||
*ok = true;
|
||||
}
|
||||
IPPWarpPerspectiveInvoker(Mat &_src, Mat &_dst, double (&_coeffs)[3][3], int &_interpolation,
|
||||
int &_borderType, const Scalar &_borderValue, ippiWarpPerspectiveFunc _func, bool *_ok) :
|
||||
ParallelLoopBody(), src(_src), dst(_dst), mode(_interpolation), coeffs(_coeffs),
|
||||
borderType(_borderType), borderValue(_borderValue), func(_func), ok(_ok)
|
||||
{
|
||||
*ok = true;
|
||||
}
|
||||
|
||||
virtual void operator() (const Range& range) const
|
||||
{
|
||||
IppiSize srcsize = {src.cols, src.rows};
|
||||
IppiRect srcroi = {0, 0, src.cols, src.rows};
|
||||
IppiRect dstroi = {0, range.start, dst.cols, range.end - range.start};
|
||||
int cnn = src.channels();
|
||||
virtual void operator() (const Range& range) const
|
||||
{
|
||||
IppiSize srcsize = {src.cols, src.rows};
|
||||
IppiRect srcroi = {0, 0, src.cols, src.rows};
|
||||
IppiRect dstroi = {0, range.start, dst.cols, range.end - range.start};
|
||||
int cnn = src.channels();
|
||||
|
||||
if( borderType == BORDER_CONSTANT )
|
||||
{
|
||||
IppiSize setSize = {dst.cols, range.end - range.start};
|
||||
void *dataPointer = dst.data + dst.step[0] * range.start;
|
||||
if( !IPPSet( borderValue, dataPointer, (int)dst.step[0], setSize, cnn, src.depth() ) )
|
||||
{
|
||||
*ok = false;
|
||||
return;
|
||||
}
|
||||
}
|
||||
if( borderType == BORDER_CONSTANT )
|
||||
{
|
||||
IppiSize setSize = {dst.cols, range.end - range.start};
|
||||
void *dataPointer = dst.data + dst.step[0] * range.start;
|
||||
if( !IPPSet( borderValue, dataPointer, (int)dst.step[0], setSize, cnn, src.depth() ) )
|
||||
{
|
||||
*ok = false;
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
IppStatus status = func(src.data, srcsize, (int)src.step[0], srcroi, dst.data, (int)dst.step[0], dstroi, coeffs, mode);
|
||||
printf("%d\n", status);
|
||||
if (status != ippStsNoErr)
|
||||
*ok = false;
|
||||
}
|
||||
IppStatus status = func(src.data, srcsize, (int)src.step[0], srcroi, dst.data, (int)dst.step[0], dstroi, coeffs, mode);
|
||||
if (status != ippStsNoErr)
|
||||
*ok = false;
|
||||
}
|
||||
private:
|
||||
Mat &src;
|
||||
Mat &dst;
|
||||
int mode;
|
||||
double (&coeffs)[3][3];
|
||||
int borderType;
|
||||
const Scalar borderValue;
|
||||
ippiWarpPerspectiveFunc func;
|
||||
bool *ok;
|
||||
Mat &src;
|
||||
Mat &dst;
|
||||
int mode;
|
||||
double (&coeffs)[3][3];
|
||||
int borderType;
|
||||
const Scalar borderValue;
|
||||
ippiWarpPerspectiveFunc func;
|
||||
bool *ok;
|
||||
|
||||
const IPPWarpPerspectiveInvoker& operator= (const IPPWarpPerspectiveInvoker&);
|
||||
const IPPWarpPerspectiveInvoker& operator= (const IPPWarpPerspectiveInvoker&);
|
||||
};
|
||||
#endif
|
||||
*/
|
||||
@@ -4464,7 +4463,7 @@ void cv::warpPerspective( InputArray _src, OutputArray _dst, InputArray _M0,
|
||||
#endif
|
||||
|
||||
/*
|
||||
#if defined (HAVE_IPP) && IPP_VERSION_MAJOR * 10 + IPP_VERSION_MINOR >= 81
|
||||
#if defined (HAVE_IPP) && IPP_VERSION_MAJOR * 100 + IPP_VERSION_MINOR >= 801
|
||||
int type = src.type(), depth = CV_MAT_DEPTH(type), cn = CV_MAT_CN(type);
|
||||
if( (depth == CV_8U || depth == CV_16U || depth == CV_32F) &&
|
||||
(cn == 1 || cn == 3 || cn == 4) &&
|
||||
|
@@ -1136,11 +1136,7 @@ private:
|
||||
Scalar borderValue;
|
||||
};
|
||||
|
||||
<<<<<<< HEAD
|
||||
#if IPP_VERSION_X100 >= 801
|
||||
=======
|
||||
#if defined (HAVE_IPP) && IPP_VERSION_MAJOR * 10 + IPP_VERSION_MINOR >= 81
|
||||
>>>>>>> cv::scaleAdd
|
||||
static bool IPPMorphReplicate(int op, const Mat &src, Mat &dst, const Mat &kernel,
|
||||
const Size& ksize, const Point &anchor, bool rectKernel)
|
||||
{
|
||||
|
Reference in New Issue
Block a user