|
|
|
@ -476,9 +476,11 @@ static bool ocl_normalizeUsingWeightMap(InputArray _weight, InputOutputArray _ma |
|
|
|
|
|
|
|
|
|
void normalizeUsingWeightMap(InputArray _weight, InputOutputArray _src) |
|
|
|
|
{ |
|
|
|
|
Mat src = _src.getMat(); |
|
|
|
|
Mat weight = _weight.getMat(); |
|
|
|
|
Mat src; |
|
|
|
|
Mat weight; |
|
|
|
|
#ifdef HAVE_TEGRA_OPTIMIZATION |
|
|
|
|
src = _src.getMat(); |
|
|
|
|
weight = _weight.getMat(); |
|
|
|
|
if(tegra::normalizeUsingWeightMap(weight, src)) |
|
|
|
|
return; |
|
|
|
|
#endif |
|
|
|
@ -488,9 +490,12 @@ void normalizeUsingWeightMap(InputArray _weight, InputOutputArray _src) |
|
|
|
|
!ocl_normalizeUsingWeightMap(_weight, _src) ) |
|
|
|
|
#endif |
|
|
|
|
{ |
|
|
|
|
src = _src.getMat(); |
|
|
|
|
weight = _weight.getMat(); |
|
|
|
|
|
|
|
|
|
CV_Assert(src.type() == CV_16SC3); |
|
|
|
|
|
|
|
|
|
if(weight.type() == CV_32FC1) |
|
|
|
|
if (weight.type() == CV_32FC1) |
|
|
|
|
{ |
|
|
|
|
for (int y = 0; y < src.rows; ++y) |
|
|
|
|
{ |
|
|
|
|