ocl: correct disabling of OpenCL code
This commit is contained in:
@@ -110,6 +110,7 @@ Rect PlaneWarper::buildMaps(Size src_size, InputArray K, InputArray R, InputArra
|
||||
_xmap.create(dsize, CV_32FC1);
|
||||
_ymap.create(dsize, CV_32FC1);
|
||||
|
||||
#ifdef HAVE_OPENCL
|
||||
if (ocl::useOpenCL())
|
||||
{
|
||||
ocl::Kernel k("buildWarpPlaneMaps", ocl::stitching::warpers_oclsrc);
|
||||
@@ -132,6 +133,7 @@ Rect PlaneWarper::buildMaps(Size src_size, InputArray K, InputArray R, InputArra
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
Mat xmap = _xmap.getMat(), ymap = _ymap.getMat();
|
||||
|
||||
@@ -310,6 +312,7 @@ void SphericalPortraitWarper::detectResultRoi(Size src_size, Point &dst_tl, Poin
|
||||
|
||||
Rect SphericalWarper::buildMaps(Size src_size, InputArray K, InputArray R, OutputArray xmap, OutputArray ymap)
|
||||
{
|
||||
#ifdef HAVE_OPENCL
|
||||
if (ocl::useOpenCL())
|
||||
{
|
||||
ocl::Kernel k("buildWarpSphericalMaps", ocl::stitching::warpers_oclsrc);
|
||||
@@ -339,7 +342,7 @@ Rect SphericalWarper::buildMaps(Size src_size, InputArray K, InputArray R, Outpu
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
return RotationWarperBase<SphericalProjector>::buildMaps(src_size, K, R, xmap, ymap);
|
||||
}
|
||||
|
||||
@@ -358,6 +361,7 @@ Point SphericalWarper::warp(InputArray src, InputArray K, InputArray R, int inte
|
||||
|
||||
Rect CylindricalWarper::buildMaps(Size src_size, InputArray K, InputArray R, OutputArray xmap, OutputArray ymap)
|
||||
{
|
||||
#ifdef HAVE_OPENCL
|
||||
if (ocl::useOpenCL())
|
||||
{
|
||||
ocl::Kernel k("buildWarpCylindricalMaps", ocl::stitching::warpers_oclsrc);
|
||||
@@ -388,7 +392,7 @@ Rect CylindricalWarper::buildMaps(Size src_size, InputArray K, InputArray R, Out
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
return RotationWarperBase<CylindricalProjector>::buildMaps(src_size, K, R, xmap, ymap);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user