added CUDA_DISABLER preprocessor commands

This commit is contained in:
Anatoly Baksheev 2012-10-01 22:37:20 +04:00
parent 46874d40df
commit 55b1d7c097
112 changed files with 376 additions and 81 deletions

View File

@ -40,6 +40,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include "opencv2/gpu/device/saturate_cast.hpp"
#include "opencv2/gpu/device/transform.hpp"
#include "opencv2/gpu/device/functional.hpp"
@ -340,3 +342,5 @@ namespace cv { namespace gpu { namespace device
# pragma clang diagnostic pop
#endif
}}} // namespace cv { namespace gpu { namespace device
#endif /* CUDA_DISABLER */

View File

@ -94,7 +94,7 @@ namespace
bool cv::gpu::TargetArchs::builtWith(cv::gpu::FeatureSet feature_set)
{
#ifdef HAVE_CUDA
#if defined HAVE_CUDA && !defined(CUDA_DISABLER)
return ::compareToSet(CUDA_ARCH_FEATURES, feature_set, std::greater_equal<int>());
#else
(void)feature_set;
@ -109,7 +109,7 @@ bool cv::gpu::TargetArchs::has(int major, int minor)
bool cv::gpu::TargetArchs::hasPtx(int major, int minor)
{
#ifdef HAVE_CUDA
#if defined HAVE_CUDA && !defined(CUDA_DISABLER)
return ::compareToSet(CUDA_ARCH_PTX, major * 10 + minor, std::equal_to<int>());
#else
(void)major;
@ -120,7 +120,7 @@ bool cv::gpu::TargetArchs::hasPtx(int major, int minor)
bool cv::gpu::TargetArchs::hasBin(int major, int minor)
{
#if defined (HAVE_CUDA)
#if defined (HAVE_CUDA) && !defined(CUDA_DISABLER)
return ::compareToSet(CUDA_ARCH_BIN, major * 10 + minor, std::equal_to<int>());
#else
(void)major;
@ -131,7 +131,7 @@ bool cv::gpu::TargetArchs::hasBin(int major, int minor)
bool cv::gpu::TargetArchs::hasEqualOrLessPtx(int major, int minor)
{
#ifdef HAVE_CUDA
#if defined HAVE_CUDA && !defined(CUDA_DISABLER)
return ::compareToSet(CUDA_ARCH_PTX, major * 10 + minor,
std::less_equal<int>());
#else
@ -149,7 +149,7 @@ bool cv::gpu::TargetArchs::hasEqualOrGreater(int major, int minor)
bool cv::gpu::TargetArchs::hasEqualOrGreaterPtx(int major, int minor)
{
#ifdef HAVE_CUDA
#if defined HAVE_CUDA && !defined(CUDA_DISABLER)
return ::compareToSet(CUDA_ARCH_PTX, major * 10 + minor,
std::greater_equal<int>());
#else
@ -161,7 +161,7 @@ bool cv::gpu::TargetArchs::hasEqualOrGreaterPtx(int major, int minor)
bool cv::gpu::TargetArchs::hasEqualOrGreaterBin(int major, int minor)
{
#ifdef HAVE_CUDA
#if defined HAVE_CUDA && !defined(CUDA_DISABLER)
return ::compareToSet(CUDA_ARCH_BIN, major * 10 + minor,
std::greater_equal<int>());
#else
@ -171,7 +171,7 @@ bool cv::gpu::TargetArchs::hasEqualOrGreaterBin(int major, int minor)
#endif
}
#ifndef HAVE_CUDA
#if !defined HAVE_CUDA || defined(CUDA_DISABLER)
#define throw_nogpu CV_Error(CV_GpuNotSupported, "The library is compiled without CUDA support")
@ -728,7 +728,7 @@ namespace
};
}
#ifndef HAVE_CUDA
#if !defined HAVE_CUDA || defined(CUDA_DISABLER)
namespace
{

View File

@ -70,7 +70,7 @@ using namespace cv::gpu;
#else
#define throw_nogl CV_Error(CV_OpenGlNotSupported, "OpenGL context doesn't exist")
#ifndef HAVE_CUDA
#if !defined HAVE_CUDA || defined(CUDA_DISABLER)
#define throw_nocuda CV_Error(CV_GpuNotSupported, "The library is compiled without CUDA support")
#else
#if defined(__GNUC__)
@ -162,7 +162,7 @@ void icvSetOpenGlFuncTab(const CvOpenGlFuncTab* tab)
void cv::gpu::setGlDevice(int device)
{
#ifndef HAVE_CUDA
#if !defined HAVE_CUDA || defined(CUDA_DISABLER)
(void)device;
throw_nocuda;
#else
@ -538,7 +538,7 @@ cv::GlBuffer::GlBuffer(InputArray mat_, Usage _usage) : rows_(0), cols_(0), type
if (kind == _InputArray::GPU_MAT)
{
#ifndef HAVE_CUDA
#if !defined HAVE_CUDA || defined(CUDA_DISABLER)
throw_nocuda;
#else
GpuMat d_mat = mat_.getGpuMat();
@ -609,7 +609,7 @@ void cv::GlBuffer::copyFrom(InputArray mat_)
}
case _InputArray::GPU_MAT:
{
#ifndef HAVE_CUDA
#if !defined HAVE_CUDA || defined(CUDA_DISABLER)
throw_nocuda;
#else
GpuMat d_mat = mat_.getGpuMat();
@ -670,7 +670,7 @@ GpuMat cv::GlBuffer::mapDevice()
throw_nogl;
return GpuMat();
#else
#ifndef HAVE_CUDA
#if !defined HAVE_CUDA || defined(CUDA_DISABLER)
throw_nocuda;
return GpuMat();
#else
@ -684,7 +684,7 @@ void cv::GlBuffer::unmapDevice()
#ifndef HAVE_OPENGL
throw_nogl;
#else
#ifndef HAVE_CUDA
#if !defined HAVE_CUDA || defined(CUDA_DISABLER)
throw_nocuda;
#else
impl_->unmapDevice();
@ -976,7 +976,7 @@ cv::GlTexture::GlTexture(InputArray mat_, bool bgra) : rows_(0), cols_(0), type_
}
case _InputArray::GPU_MAT:
{
#ifndef HAVE_CUDA
#if !defined HAVE_CUDA || defined(CUDA_DISABLER)
throw_nocuda;
#else
GpuMat d_mat = mat_.getGpuMat();
@ -1056,7 +1056,7 @@ void cv::GlTexture::copyFrom(InputArray mat_, bool bgra)
}
case _InputArray::GPU_MAT:
{
#ifndef HAVE_CUDA
#if !defined HAVE_CUDA || defined(CUDA_DISABLER)
throw_nocuda;
#else
GpuMat d_mat = mat_.getGpuMat();

View File

@ -31,7 +31,7 @@ void printOsInfo()
void printCudaInfo()
{
#ifndef HAVE_CUDA
#if !defined HAVE_CUDA || defined(CUDA_DISABLER)
cout << "OpenCV was built without CUDA support \n" << endl;
#else
int driver;
@ -99,7 +99,7 @@ int main(int argc, char** argv)
int device = cmd.get<int>("device");
bool cpu = cmd.has("cpu");
#ifndef HAVE_CUDA
#if !defined HAVE_CUDA || defined(CUDA_DISABLER)
cpu = true;
#endif

View File

@ -46,7 +46,7 @@ using namespace cv;
using namespace cv::gpu;
using namespace std;
#if !defined (HAVE_CUDA)
#if !defined (HAVE_CUDA) || defined (CUDA_DISABLER)
void cv::gpu::gemm(const GpuMat&, const GpuMat&, double, const GpuMat&, double, GpuMat&, int, Stream&) { throw_nogpu(); }
void cv::gpu::transpose(const GpuMat&, GpuMat&, Stream&) { throw_nogpu(); }

View File

@ -42,7 +42,7 @@
#include "precomp.hpp"
#ifndef HAVE_CUDA
#if !defined HAVE_CUDA || defined(CUDA_DISABLER)
cv::gpu::GMG_GPU::GMG_GPU() { throw_nogpu(); }
void cv::gpu::GMG_GPU::initialize(cv::Size, float, float) { throw_nogpu(); }

View File

@ -42,7 +42,7 @@
#include "precomp.hpp"
#ifndef HAVE_CUDA
#if !defined HAVE_CUDA || defined(CUDA_DISABLER)
cv::gpu::MOG_GPU::MOG_GPU(int) { throw_nogpu(); }
void cv::gpu::MOG_GPU::initialize(cv::Size, int) { throw_nogpu(); }

View File

@ -42,7 +42,7 @@
#include "precomp.hpp"
#ifndef HAVE_CUDA
#if !defined HAVE_CUDA || defined(CUDA_DISABLER)
cv::gpu::VIBE_GPU::VIBE_GPU(unsigned long) { throw_nogpu(); }
void cv::gpu::VIBE_GPU::initialize(const GpuMat&, Stream&) { throw_nogpu(); }

View File

@ -46,7 +46,7 @@ using namespace cv;
using namespace cv::gpu;
using namespace std;
#if !defined (HAVE_CUDA)
#if !defined (HAVE_CUDA) || defined (CUDA_DISABLER)
cv::gpu::DisparityBilateralFilter::DisparityBilateralFilter(int, int, int) { throw_nogpu(); }
cv::gpu::DisparityBilateralFilter::DisparityBilateralFilter(int, int, int, float, float, float) { throw_nogpu(); }

View File

@ -46,7 +46,7 @@ using namespace std;
using namespace cv;
using namespace cv::gpu;
#if !defined (HAVE_CUDA)
#if !defined (HAVE_CUDA) || defined (CUDA_DISABLER)
void cv::gpu::blendLinear(const GpuMat&, const GpuMat&, const GpuMat&, const GpuMat&, GpuMat&, Stream&) { throw_nogpu(); }

View File

@ -46,7 +46,7 @@ using namespace cv;
using namespace cv::gpu;
using namespace std;
#if !defined (HAVE_CUDA)
#if !defined (HAVE_CUDA) || defined (CUDA_DISABLER)
cv::gpu::BFMatcher_GPU::BFMatcher_GPU(int) { throw_nogpu(); }
void cv::gpu::BFMatcher_GPU::add(const vector<GpuMat>&) { throw_nogpu(); }

View File

@ -46,7 +46,7 @@ using namespace cv;
using namespace cv::gpu;
using namespace std;
#if !defined(HAVE_CUDA)
#if !defined HAVE_CUDA || defined(CUDA_DISABLER)
void cv::gpu::transformPoints(const GpuMat&, const Mat&, const Mat&, GpuMat&, Stream&) { throw_nogpu(); }

View File

@ -48,7 +48,7 @@ using namespace cv;
using namespace cv::gpu;
using namespace std;
#if !defined (HAVE_CUDA)
#if !defined (HAVE_CUDA) || defined (CUDA_DISABLER)
cv::gpu::CascadeClassifier_GPU::CascadeClassifier_GPU() { throw_nogpu(); }
cv::gpu::CascadeClassifier_GPU::CascadeClassifier_GPU(const string&) { throw_nogpu(); }

View File

@ -45,7 +45,7 @@
using namespace cv;
using namespace cv::gpu;
#if !defined (HAVE_CUDA)
#if !defined (HAVE_CUDA) || defined (CUDA_DISABLER)
void cv::gpu::cvtColor(const GpuMat&, GpuMat&, int, int, Stream&) { throw_nogpu(); }
void cv::gpu::swapChannels(GpuMat&, const int[], Stream&) { throw_nogpu(); }

View File

@ -58,6 +58,8 @@
source and converts to output in ARGB format
*/
#if !defined CUDA_DISABLER
#include "opencv2/gpu/device/common.hpp"
namespace cv { namespace gpu { namespace device {
@ -206,3 +208,5 @@ namespace cv { namespace gpu { namespace device {
}
}
}}}
#endif /* CUDA_DISABLER */

View File

@ -40,6 +40,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include "internal_shared.hpp"
#include "opencv2/gpu/device/limits.hpp"
#include "opencv2/gpu/device/vec_distance.hpp"
@ -1160,3 +1162,6 @@ namespace cv { namespace gpu { namespace device
template void match2Hamming_gpu<int >(const PtrStepSzb& query, const PtrStepSzb& trains, const PtrStepSz<PtrStepb>& masks, const PtrStepSzb& trainIdx, const PtrStepSzb& imgIdx, const PtrStepSzb& distance, int cc, cudaStream_t stream);
} // namespace bf_knnmatch
}}} // namespace cv { namespace gpu { namespace device {
#endif /* CUDA_DISABLER */

View File

@ -40,6 +40,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include "internal_shared.hpp"
#include "opencv2/gpu/device/limits.hpp"
#include "opencv2/gpu/device/vec_distance.hpp"
@ -778,3 +780,6 @@ namespace cv { namespace gpu { namespace device
template void matchHamming_gpu<int >(const PtrStepSzb& query, const PtrStepSzb& trains, const PtrStepSz<PtrStepb>& masks, const PtrStepSzi& trainIdx, const PtrStepSzi& imgIdx, const PtrStepSzf& distance, int cc, cudaStream_t stream);
} // namespace bf_match
}}} // namespace cv { namespace gpu { namespace device {
#endif /* CUDA_DISABLER */

View File

@ -40,6 +40,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include "internal_shared.hpp"
#include "opencv2/gpu/device/limits.hpp"
#include "opencv2/gpu/device/vec_distance.hpp"
@ -465,3 +467,6 @@ namespace cv { namespace gpu { namespace device
template void matchHamming_gpu<int >(const PtrStepSzb& query, const PtrStepSzb* trains, int n, float maxDistance, const PtrStepSzb* masks, const PtrStepSzi& trainIdx, const PtrStepSzi& imgIdx, const PtrStepSzf& distance, const PtrStepSz<unsigned int>& nMatches, int cc, cudaStream_t stream);
} // namespace bf_radius_match
}}} // namespace cv { namespace gpu { namespace device
#endif /* CUDA_DISABLER */

View File

@ -40,6 +40,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include "opencv2/gpu/device/common.hpp"
#include "opencv2/gpu/device/vec_traits.hpp"
#include "opencv2/gpu/device/limits.hpp"
@ -251,3 +253,6 @@ namespace cv { namespace gpu { namespace device {
template void update_gpu<float4 >(PtrStepSzb frame, PtrStepb fgmask, PtrStepSzi colors, PtrStepf weights, PtrStepi nfeatures, int frameNum, float learningRate, bool updateBackgroundModel, cudaStream_t stream);
}
}}}
#endif /* CUDA_DISABLER */

View File

@ -40,6 +40,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include "opencv2/gpu/device/common.hpp"
#include "opencv2/gpu/device/vec_traits.hpp"
#include "opencv2/gpu/device/vec_math.hpp"
@ -757,3 +759,6 @@ namespace cv { namespace gpu { namespace device
}
}
}}}
#endif /* CUDA_DISABLER */

View File

@ -40,6 +40,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include "opencv2/gpu/device/common.hpp"
namespace cv { namespace gpu { namespace device
@ -251,3 +253,6 @@ namespace cv { namespace gpu { namespace device
}
}
}}}
#endif /* CUDA_DISABLER */

View File

@ -41,6 +41,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include "internal_shared.hpp"
#include "opencv2/gpu/device/vec_traits.hpp"
@ -194,3 +196,6 @@ OCV_INSTANTIATE_BILATERAL_FILTER(float)
//OCV_INSTANTIATE_BILATERAL_FILTER(float2)
OCV_INSTANTIATE_BILATERAL_FILTER(float3)
OCV_INSTANTIATE_BILATERAL_FILTER(float4)
#endif /* CUDA_DISABLER */

View File

@ -40,6 +40,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include "internal_shared.hpp"
namespace cv { namespace gpu { namespace device
@ -114,3 +116,6 @@ namespace cv { namespace gpu { namespace device
}
} // namespace blend
}}} // namespace cv { namespace gpu { namespace device
#endif /* CUDA_DISABLER */

View File

@ -40,6 +40,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include "internal_shared.hpp"
#include "opencv2/gpu/device/transform.hpp"
#include "opencv2/gpu/device/functional.hpp"
@ -189,3 +191,6 @@ namespace cv { namespace gpu { namespace device
}
} // namespace solvepnp_ransac
}}} // namespace cv { namespace gpu { namespace device
#endif /* CUDA_DISABLER */

View File

@ -40,6 +40,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include <utility>
#include <algorithm>
#include "internal_shared.hpp"
@ -494,3 +496,6 @@ namespace cv { namespace gpu { namespace device
}
} // namespace canny
}}} // namespace cv { namespace gpu { namespace device
#endif /* CUDA_DISABLER */

View File

@ -39,6 +39,8 @@
// the use of this software, even if advised of the possibility of such damage.
//M*/
#if !defined CUDA_DISABLER
#include <opencv2/gpu/device/common.hpp>
#include <opencv2/gpu/device/vec_traits.hpp>
#include <opencv2/gpu/device/vec_math.hpp>
@ -525,4 +527,6 @@ namespace cv { namespace gpu { namespace device
cudaSafeCall( cudaDeviceSynchronize() );
}
}
} } }
} } }
#endif /* CUDA_DISABLER */

View File

@ -40,6 +40,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include <internal_shared.hpp>
#include <opencv2/gpu/device/transform.hpp>
#include <opencv2/gpu/device/color.hpp>
@ -378,3 +380,5 @@ namespace cv { namespace gpu { namespace device
#undef OPENCV_GPU_IMPLEMENT_CVTCOLOR_ALL
#undef OPENCV_GPU_IMPLEMENT_CVTCOLOR_8U32F
}}} // namespace cv { namespace gpu { namespace device
#endif /* CUDA_DISABLER */

View File

@ -41,6 +41,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include "internal_shared.hpp"
#include "opencv2/gpu/device/saturate_cast.hpp"
#include "opencv2/gpu/device/vec_math.hpp"
@ -378,3 +380,6 @@ namespace cv { namespace gpu { namespace device
template void linearColumnFilter_gpu<float , float >(PtrStepSzb src, PtrStepSzb dst, const float kernel[], int ksize, int anchor, int brd_type, int cc, cudaStream_t stream);
} // namespace column_filter
}}} // namespace cv { namespace gpu { namespace device
#endif /* CUDA_DISABLER */

View File

@ -40,6 +40,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include "internal_shared.hpp"
#include "opencv2/gpu/device/border_interpolate.hpp"
@ -125,3 +127,5 @@ namespace cv { namespace gpu { namespace device
template void copyMakeBorder_gpu<float, 4>(const PtrStepSzb& src, const PtrStepSzb& dst, int top, int left, int borderMode, const float* borderValue, cudaStream_t stream);
} // namespace imgproc
}}} // namespace cv { namespace gpu { namespace device
#endif /* CUDA_DISABLER */

View File

@ -40,6 +40,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include <opencv2/gpu/device/common.hpp>
#include <opencv2/gpu/device/vec_traits.hpp>
#include <opencv2/gpu/device/vec_math.hpp>
@ -325,3 +327,5 @@ namespace cv { namespace gpu {
template void Bayer2BGR_16u_gpu<4>(PtrStepSzb src, PtrStepSzb dst, bool blue_last, bool start_with_green, cudaStream_t stream);
}
}}
#endif /* CUDA_DISABLER */

View File

@ -40,6 +40,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include "internal_shared.hpp"
#include "opencv2/gpu/device/limits.hpp"
@ -217,3 +219,5 @@ namespace cv { namespace gpu { namespace device
template void disp_bilateral_filter<short>(PtrStepSz<short> disp, PtrStepSzb img, int channels, int iters, cudaStream_t stream);
} // namespace bilateral_filter
}}} // namespace cv { namespace gpu { namespace device
#endif /* CUDA_DISABLER */

View File

@ -40,6 +40,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include "internal_shared.hpp"
#include "opencv2/gpu/device/functional.hpp"
#include "opencv2/gpu/device/vec_math.hpp"
@ -2367,3 +2369,5 @@ namespace cv { namespace gpu { namespace device
template void addWeighted_gpu<double, double, float>(const PtrStepSzb& src1, double alpha, const PtrStepSzb& src2, double beta, double gamma, const PtrStepSzb& dst, cudaStream_t stream);
template void addWeighted_gpu<double, double, double>(const PtrStepSzb& src1, double alpha, const PtrStepSzb& src2, double beta, double gamma, const PtrStepSzb& dst, cudaStream_t stream);
}}} // namespace cv { namespace gpu { namespace device
#endif /* CUDA_DISABLER */

View File

@ -45,6 +45,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include "opencv2/gpu/device/common.hpp"
#include "opencv2/gpu/device/utility.hpp"
@ -383,3 +385,6 @@ namespace cv { namespace gpu { namespace device
}
} // namespace fast
}}}
#endif /* CUDA_DISABLER */

View File

@ -40,6 +40,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include "opencv2/gpu/device/common.hpp"
#include "opencv2/gpu/device/vec_math.hpp"
#include "opencv2/gpu/device/limits.hpp"
@ -842,3 +844,5 @@ namespace bgfg
template void updateBackgroundModel_gpu<uchar4, uchar4, uchar3>(PtrStepSzb prevFrame, PtrStepSzb curFrame, PtrStepSzb Ftd, PtrStepSzb Fbd, PtrStepSzb foreground, PtrStepSzb background, int deltaC, int deltaCC, float alpha1, float alpha2, float alpha3, int N1c, int N1cc, int N2c, int N2cc, float T, cudaStream_t stream);
template void updateBackgroundModel_gpu<uchar4, uchar4, uchar4>(PtrStepSzb prevFrame, PtrStepSzb curFrame, PtrStepSzb Ftd, PtrStepSzb Fbd, PtrStepSzb foreground, PtrStepSzb background, int deltaC, int deltaCC, float alpha1, float alpha2, float alpha3, int N1c, int N1cc, int N2c, int N2cc, float T, cudaStream_t stream);
}
#endif /* CUDA_DISABLER */

View File

@ -45,6 +45,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include <thrust/sort.h>
#include "opencv2/gpu/device/common.hpp"
@ -144,3 +146,6 @@ namespace cv { namespace gpu { namespace device
}
} // namespace optical_flow
}}}
#endif /* CUDA_DISABLER */

View File

@ -41,6 +41,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include "thrust/device_ptr.h"
#include "thrust/remove.h"
#include "thrust/functional.h"
@ -113,3 +115,6 @@ void calcWobbleSuppressionMaps(
}
}}}}
#endif /* CUDA_DISABLER */

View File

@ -41,6 +41,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include "internal_shared.hpp"
#include "opencv2/gpu/device/utility.hpp"
#include "opencv2/gpu/device/saturate_cast.hpp"
@ -217,3 +219,6 @@ namespace cv { namespace gpu { namespace device
}
} // namespace hist
}}} // namespace cv { namespace gpu { namespace device
#endif /* CUDA_DISABLER */

View File

@ -40,6 +40,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include "internal_shared.hpp"
namespace cv { namespace gpu { namespace device
@ -864,3 +866,6 @@ namespace cv { namespace gpu { namespace device
void resize_8UC4(const PtrStepSzb& src, PtrStepSzb dst) { resize_for_hog<uchar4>(src, dst, resize8UC4_tex); }
} // namespace hog
}}} // namespace cv { namespace gpu { namespace device
#endif /* CUDA_DISABLER */

View File

@ -40,6 +40,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include <thrust/sort.h>
#include "opencv2/gpu/device/common.hpp"
#include "opencv2/gpu/device/emulation.hpp"
@ -1505,3 +1507,6 @@ namespace cv { namespace gpu { namespace device
}
}
}}}
#endif /* CUDA_DISABLER */

View File

@ -40,6 +40,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include "internal_shared.hpp"
#include "opencv2/gpu/device/vec_traits.hpp"
#include "opencv2/gpu/device/vec_math.hpp"
@ -997,3 +999,6 @@ namespace cv { namespace gpu { namespace device
template void filter2D_gpu<float4, float4>(PtrStepSzb srcWhole, int ofsX, int ofsY, PtrStepSzb dst, int kWidth, int kHeight, int anchorX, int anchorY, const float* kernel, int borderMode, const float* borderValue, cudaStream_t stream);
} // namespace imgproc
}}} // namespace cv { namespace gpu { namespace device {
#endif /* CUDA_DISABLER */

View File

@ -40,6 +40,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include "opencv2/gpu/device/common.hpp"
namespace cv { namespace gpu { namespace device
@ -383,3 +385,5 @@ namespace cv { namespace gpu { namespace device
}
}
}}}
#endif /* CUDA_DISABLER */

View File

@ -40,6 +40,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include <opencv2/gpu/device/lbp.hpp>
#include <opencv2/gpu/device/vec_traits.hpp>
#include <opencv2/gpu/device/saturate_cast.hpp>
@ -295,4 +297,6 @@ namespace cv { namespace gpu { namespace device
lbp_cascade<<<grid, block>>>(cascade, frameW, frameH, windowW, windowH, initialScale, factor, workAmount, integral.ptr(), integral.step / sizeof(int), objects, classified);
}
}
}}}
}}}
#endif /* CUDA_DISABLER */

View File

@ -40,6 +40,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include "internal_shared.hpp"
#include "opencv2/gpu/device/vec_math.hpp"
@ -909,3 +911,6 @@ namespace cv { namespace gpu { namespace device
}
} //namespace match_template
}}} // namespace cv { namespace gpu { namespace device
#endif /* CUDA_DISABLER */

View File

@ -40,6 +40,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include "internal_shared.hpp"
namespace cv { namespace gpu { namespace device
@ -211,3 +213,5 @@ namespace cv { namespace gpu { namespace device
}
} // namespace mathfunc
}}} // namespace cv { namespace gpu { namespace device
#endif /* CUDA_DISABLER */

View File

@ -40,6 +40,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include "internal_shared.hpp"
#include "opencv2/gpu/device/limits.hpp"
#include "opencv2/gpu/device/saturate_cast.hpp"
@ -2097,3 +2099,5 @@ namespace cv { namespace gpu { namespace device
template void reduceCols_gpu<float, float, float>(const PtrStepSzb& src, int cn, const PtrStepSzb& dst, int reduceOp, cudaStream_t stream);
} // namespace mattrix_reductions
}}} // namespace cv { namespace gpu { namespace device
#endif /* CUDA_DISABLER */

View File

@ -41,6 +41,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include "internal_shared.hpp"
#include "opencv2/gpu/device/vec_traits.hpp"
@ -168,3 +170,5 @@ namespace cv { namespace gpu { namespace device
template void nlm_bruteforce_gpu<uchar3>(const PtrStepSzb&, PtrStepSzb, int, int, float, int, cudaStream_t);
}
}}}
#endif /* CUDA_DISABLER */

View File

@ -40,6 +40,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include "opencv2/gpu/device/common.hpp"
namespace cv { namespace gpu { namespace device
@ -214,3 +216,5 @@ namespace cv { namespace gpu { namespace device
}
}
}}}
#endif /* CUDA_DISABLER */

View File

@ -40,6 +40,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include <stdio.h>
#include "internal_shared.hpp"
#include "opencv2/gpu/device/common.hpp"
@ -645,3 +647,5 @@ namespace cv { namespace gpu { namespace device { namespace optflow_farneback
}}}} // namespace cv { namespace gpu { namespace device { namespace optflow_farneback
#endif /* CUDA_DISABLER */

View File

@ -45,6 +45,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include <thrust/sort.h>
#include "opencv2/gpu/device/common.hpp"
@ -415,4 +417,6 @@ namespace cv { namespace gpu { namespace device
cudaSafeCall( cudaDeviceSynchronize() );
}
}
}}}
}}}
#endif /* CUDA_DISABLER */

View File

@ -40,6 +40,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include "opencv2/gpu/device/common.hpp"
#include "opencv2/gpu/device/border_interpolate.hpp"
#include "opencv2/gpu/device/vec_traits.hpp"
@ -221,3 +223,6 @@ namespace cv { namespace gpu { namespace device
template void pyrDown_gpu<float4>(PtrStepSzb src, PtrStepSzb dst, cudaStream_t stream);
} // namespace imgproc
}}} // namespace cv { namespace gpu { namespace device
#endif /* CUDA_DISABLER */

View File

@ -40,6 +40,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include "internal_shared.hpp"
#include "opencv2/gpu/device/border_interpolate.hpp"
#include "opencv2/gpu/device/vec_traits.hpp"
@ -190,3 +192,5 @@ namespace cv { namespace gpu { namespace device
template void pyrUp_gpu<float4>(PtrStepSzb src, PtrStepSzb dst, cudaStream_t stream);
} // namespace imgproc
}}} // namespace cv { namespace gpu { namespace device
#endif /* CUDA_DISABLER */

View File

@ -45,6 +45,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include "opencv2/gpu/device/common.hpp"
#include "opencv2/gpu/device/utility.hpp"
#include "opencv2/gpu/device/functional.hpp"
@ -678,3 +680,5 @@ namespace cv { namespace gpu { namespace device
}
}
}}}
#endif /* CUDA_DISABLER */

View File

@ -40,6 +40,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include "internal_shared.hpp"
#include "opencv2/gpu/device/border_interpolate.hpp"
#include "opencv2/gpu/device/vec_traits.hpp"
@ -267,3 +269,6 @@ namespace cv { namespace gpu { namespace device
template void remap_gpu<float4>(PtrStepSzb src, PtrStepSzb srcWhole, int xoff, int yoff, PtrStepSzf xmap, PtrStepSzf ymap, PtrStepSzb dst, int interpolation, int borderMode, const float* borderValue, cudaStream_t stream, int cc);
} // namespace imgproc
}}} // namespace cv { namespace gpu { namespace device
#endif /* CUDA_DISABLER */

View File

@ -40,6 +40,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include "internal_shared.hpp"
#include "opencv2/gpu/device/border_interpolate.hpp"
#include "opencv2/gpu/device/vec_traits.hpp"
@ -295,3 +297,6 @@ namespace cv { namespace gpu { namespace device
} // namespace imgproc
}}} // namespace cv { namespace gpu { namespace device
#endif /* CUDA_DISABLER */

View File

@ -40,6 +40,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include "opencv2/gpu/device/common.hpp"
#include "opencv2/gpu/device/vec_traits.hpp"
@ -169,3 +171,5 @@ namespace cv { namespace gpu { namespace device
}
}
}}}
#endif /* CUDA_DISABLER */

View File

@ -41,6 +41,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include "internal_shared.hpp"
#include "opencv2/gpu/device/saturate_cast.hpp"
#include "opencv2/gpu/device/vec_math.hpp"
@ -377,3 +379,6 @@ namespace cv { namespace gpu { namespace device
template void linearRowFilter_gpu<float , float >(PtrStepSzb src, PtrStepSzb dst, const float kernel[], int ksize, int anchor, int brd_type, int cc, cudaStream_t stream);
} // namespace row_filter
}}} // namespace cv { namespace gpu { namespace device
#endif /* CUDA_DISABLER */

View File

@ -40,6 +40,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include "internal_shared.hpp"
namespace cv { namespace gpu { namespace device
@ -504,3 +506,6 @@ namespace cv { namespace gpu { namespace device
}
} // namespace split_merge
}}} // namespace cv { namespace gpu { namespace device
#endif /* CUDA_DISABLER */

View File

@ -40,6 +40,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include "internal_shared.hpp"
namespace cv { namespace gpu { namespace device
@ -533,3 +535,6 @@ namespace cv { namespace gpu { namespace device
}
} // namespace stereobm
}}} // namespace cv { namespace gpu { namespace device
#endif /* CUDA_DISABLER */

View File

@ -40,6 +40,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include "internal_shared.hpp"
#include "opencv2/gpu/device/saturate_cast.hpp"
#include "opencv2/gpu/device/limits.hpp"
@ -532,3 +534,5 @@ namespace cv { namespace gpu { namespace device
template void output_gpu<float>(const PtrStepSzb& u, const PtrStepSzb& d, const PtrStepSzb& l, const PtrStepSzb& r, const PtrStepSzb& data, const PtrStepSz<short>& disp, cudaStream_t stream);
} // namespace stereobp
}}} // namespace cv { namespace gpu { namespace device
#endif /* CUDA_DISABLER */

View File

@ -40,6 +40,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include "internal_shared.hpp"
#include "opencv2/gpu/device/saturate_cast.hpp"
#include "opencv2/gpu/device/limits.hpp"
@ -886,3 +888,5 @@ namespace cv { namespace gpu { namespace device
const PtrStepSz<short>& disp, int nr_plane, cudaStream_t stream);
} // namespace stereocsbp
}}} // namespace cv { namespace gpu { namespace device {
#endif /* CUDA_DISABLER */

View File

@ -45,6 +45,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include "internal_shared.hpp"
#include "opencv2/gpu/device/limits.hpp"
#include "opencv2/gpu/device/saturate_cast.hpp"
@ -990,3 +992,6 @@ namespace cv { namespace gpu { namespace device
}
} // namespace surf
}}} // namespace cv { namespace gpu { namespace device
#endif /* CUDA_DISABLER */

View File

@ -40,6 +40,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include "internal_shared.hpp"
#include "opencv2/gpu/device/border_interpolate.hpp"
#include "opencv2/gpu/device/vec_traits.hpp"
@ -382,3 +384,6 @@ namespace cv { namespace gpu { namespace device
template void warpPerspective_gpu<float4>(PtrStepSzb src, PtrStepSzb srcWhole, int xoff, int yoff, float coeffs[3 * 3], PtrStepSzb dst, int interpolation, int borderMode, const float* borderValue, cudaStream_t stream, int cc);
} // namespace imgproc
}}} // namespace cv { namespace gpu { namespace device
#endif /* CUDA_DISABLER */

View File

@ -45,8 +45,26 @@
using namespace cv;
using namespace cv::gpu;
#if defined HAVE_CUDA
#if !defined (HAVE_CUDA)
struct Stream::Impl
{
static cudaStream_t getStream(const Impl* impl) { return impl ? impl->stream : 0; }
cudaStream_t stream;
int ref_counter;
};
#include "opencv2/gpu/stream_accessor.hpp"
CV_EXPORTS cudaStream_t cv::gpu::StreamAccessor::getStream(const Stream& stream)
{
return Stream::Impl::getStream(stream.impl);
};
#endif /* !defined (HAVE_CUDA) */
#if !defined (HAVE_CUDA) || defined (CUDA_DISABLER)
void cv::gpu::Stream::create() { throw_nogpu(); }
void cv::gpu::Stream::release() { throw_nogpu(); }
@ -69,8 +87,6 @@ cv::gpu::Stream::operator bool() const { throw_nogpu(); return false; }
#else /* !defined (HAVE_CUDA) */
#include "opencv2/gpu/stream_accessor.hpp"
namespace cv { namespace gpu
{
void copyWithMask(const GpuMat& src, GpuMat& dst, const GpuMat& mask, cudaStream_t stream);
@ -79,13 +95,6 @@ namespace cv { namespace gpu
void setTo(GpuMat& src, Scalar s, const GpuMat& mask, cudaStream_t stream);
}}
struct Stream::Impl
{
static cudaStream_t getStream(const Impl* impl) { return impl ? impl->stream : 0; }
cudaStream_t stream;
int ref_counter;
};
namespace
{
template<class S, class D> void devcopy(const S& src, D& dst, cudaStream_t s, cudaMemcpyKind k)
@ -96,11 +105,6 @@ namespace
};
}
CV_EXPORTS cudaStream_t cv::gpu::StreamAccessor::getStream(const Stream& stream)
{
return Stream::Impl::getStream(stream.impl);
};
void cv::gpu::Stream::create()
{
if (impl)

View File

@ -45,7 +45,7 @@
using namespace cv;
using namespace cv::gpu;
#if !defined (HAVE_CUDA)
#if !defined (HAVE_CUDA) || defined (CUDA_DISABLER)
void cv::gpu::bilateralFilter(const GpuMat&, GpuMat&, int, float, float, int, Stream&) { throw_nogpu(); }
void cv::gpu::nonLocalMeans(const GpuMat&, GpuMat&, float, int, int, int, Stream&) { throw_nogpu(); }

View File

@ -45,7 +45,7 @@
using namespace cv;
using namespace cv::gpu;
#if !defined (HAVE_CUDA)
#if !defined (HAVE_CUDA) || defined (CUDA_DISABLER)
void cv::gpu::add(const GpuMat&, const GpuMat&, GpuMat&, const GpuMat&, int, Stream&) { throw_nogpu(); }
void cv::gpu::add(const GpuMat&, const Scalar&, GpuMat&, const GpuMat&, int, Stream&) { throw_nogpu(); }

View File

@ -46,7 +46,7 @@ using namespace cv;
using namespace cv::gpu;
using namespace std;
#if !defined (HAVE_CUDA)
#if !defined (HAVE_CUDA) || defined (CUDA_DISABLER)
cv::gpu::FAST_GPU::FAST_GPU(int, bool, double) { throw_nogpu(); }
void cv::gpu::FAST_GPU::operator ()(const GpuMat&, const GpuMat&, GpuMat&) { throw_nogpu(); }

View File

@ -42,7 +42,7 @@
#include "precomp.hpp"
#ifndef HAVE_CUDA
#if !defined HAVE_CUDA || defined(CUDA_DISABLER)
class cv::gpu::FGDStatModel::Impl
{

View File

@ -46,7 +46,7 @@ using namespace cv;
using namespace cv::gpu;
#if !defined (HAVE_CUDA)
#if !defined (HAVE_CUDA) || defined (CUDA_DISABLER)
Ptr<FilterEngine_GPU> cv::gpu::createFilter2D_GPU(const Ptr<BaseFilter_GPU>&, int, int) { throw_nogpu(); return Ptr<FilterEngine_GPU>(0); }
Ptr<FilterEngine_GPU> cv::gpu::createSeparableFilter_GPU(const Ptr<BaseRowFilter_GPU>&, const Ptr<BaseColumnFilter_GPU>&, int, int, int) { throw_nogpu(); return Ptr<FilterEngine_GPU>(0); }

View File

@ -46,7 +46,7 @@ using namespace std;
using namespace cv;
using namespace cv::gpu;
#if !defined (HAVE_CUDA)
#if !defined (HAVE_CUDA) || defined (CUDA_DISABLER)
void cv::gpu::GoodFeaturesToTrackDetector_GPU::operator ()(const GpuMat&, GpuMat&, const GpuMat&) { throw_nogpu(); }

View File

@ -46,7 +46,7 @@ using namespace std;
using namespace cv;
using namespace cv::gpu;
#ifndef HAVE_CUDA
#if !defined HAVE_CUDA || defined(CUDA_DISABLER)
void cv::gpu::compactPoints(GpuMat&, GpuMat&, const GpuMat&) { throw_nogpu(); }
void cv::gpu::calcWobbleSuppressionMaps(

View File

@ -42,7 +42,7 @@
#include "precomp.hpp"
#if !defined (HAVE_CUDA)
#if !defined (HAVE_CUDA) || defined (CUDA_DISABLER)
void cv::gpu::graphcut(GpuMat&, GpuMat&, GpuMat&, GpuMat&, GpuMat&, GpuMat&, GpuMat&, Stream&) { throw_nogpu(); }
void cv::gpu::graphcut(GpuMat&, GpuMat&, GpuMat&, GpuMat&, GpuMat&, GpuMat&, GpuMat&, GpuMat&, GpuMat&, GpuMat&, GpuMat&, Stream&) { throw_nogpu(); }

View File

@ -42,7 +42,7 @@
#include "precomp.hpp"
#if !defined (HAVE_CUDA)
#if !defined (HAVE_CUDA) || defined (CUDA_DISABLER)
cv::gpu::HOGDescriptor::HOGDescriptor(Size, Size, Size, Size, int, double, double, bool, int) { throw_nogpu(); }
size_t cv::gpu::HOGDescriptor::getDescriptorSize() const { throw_nogpu(); return 0; }

View File

@ -46,7 +46,7 @@ using namespace std;
using namespace cv;
using namespace cv::gpu;
#if !defined (HAVE_CUDA)
#if !defined (HAVE_CUDA) || defined (CUDA_DISABLER)
void cv::gpu::HoughLines(const GpuMat&, GpuMat&, float, float, int, bool, int) { throw_nogpu(); }
void cv::gpu::HoughLines(const GpuMat&, GpuMat&, HoughLinesBuf&, float, float, int, bool, int) { throw_nogpu(); }

View File

@ -45,7 +45,7 @@
using namespace cv;
using namespace cv::gpu;
#if !defined (HAVE_CUDA)
#if !defined (HAVE_CUDA) || defined (CUDA_DISABLER)
void cv::gpu::meanShiftFiltering(const GpuMat&, GpuMat&, int, int, TermCriteria, Stream&) { throw_nogpu(); }
void cv::gpu::meanShiftProc(const GpuMat&, GpuMat&, GpuMat&, int, int, TermCriteria, Stream&) { throw_nogpu(); }

View File

@ -46,7 +46,7 @@ using namespace cv;
using namespace cv::gpu;
using namespace std;
#if !defined (HAVE_CUDA)
#if !defined (HAVE_CUDA) || defined (CUDA_DISABLER)
void cv::gpu::matchTemplate(const GpuMat&, const GpuMat&, GpuMat&, int, Stream&) { throw_nogpu(); }

View File

@ -178,7 +178,7 @@ bool cv::gpu::CudaMem::empty() const
return data == 0;
}
#if !defined (HAVE_CUDA)
#if !defined (HAVE_CUDA) || defined (CUDA_DISABLER)
void cv::gpu::registerPageLocked(Mat&) { throw_nogpu(); }
void cv::gpu::unregisterPageLocked(Mat&) { throw_nogpu(); }

View File

@ -45,7 +45,7 @@
using namespace cv;
using namespace cv::gpu;
#if !defined (HAVE_CUDA)
#if !defined (HAVE_CUDA) || defined (CUDA_DISABLER)
void cv::gpu::meanStdDev(const GpuMat&, Scalar&, Scalar&) { throw_nogpu(); }
void cv::gpu::meanStdDev(const GpuMat&, Scalar&, Scalar&, GpuMat&) { throw_nogpu(); }

View File

@ -42,7 +42,7 @@
#include "precomp.hpp"
#if !defined(HAVE_CUDA)
#if !defined HAVE_CUDA || defined(CUDA_DISABLER)
void cv::gpu::meanShiftSegmentation(const GpuMat&, Mat&, int, int, int, TermCriteria) { throw_nogpu(); }
@ -386,4 +386,4 @@ void cv::gpu::meanShiftSegmentation(const GpuMat& src, Mat& dst, int sp, int sr,
}
}
#endif // #if !defined (HAVE_CUDA)
#endif // #if !defined (HAVE_CUDA) || defined (CUDA_DISABLER)

View File

@ -56,6 +56,8 @@
//
////////////////////////////////////////////////////////////////////////////////
#if !defined CUDA_DISABLER
#include <iostream>
#include <vector>
#include <memory>
@ -1160,3 +1162,5 @@ NCVStatus NCVBroxOpticalFlow(const NCVBroxOpticalFlowDescriptor desc,
return NCV_SUCCESS;
}
#endif /* CUDA_DISABLER */

View File

@ -55,6 +55,8 @@
//
////////////////////////////////////////////////////////////////////////////////
#if !defined CUDA_DISABLER
#include <algorithm>
#include <cstdio>
@ -2314,3 +2316,5 @@ NCVStatus ncvHaarStoreNVBIN_host(const std::string &filename,
fclose(fp);
return NCV_SUCCESS;
}
#endif /* CUDA_DISABLER */

View File

@ -39,6 +39,7 @@
//
//M*/
#if !defined CUDA_DISABLER
#include <vector>
#include <cuda_runtime.h>
@ -2576,3 +2577,5 @@ NCVStatus nppiStResize_32f_C1R(const Ncv32f *pSrc,
return status;
}
#endif /* CUDA_DISABLER */

View File

@ -39,6 +39,8 @@
//
//M*/
#if !defined CUDA_DISABLER
#include <iostream>
#include <string>
@ -905,3 +907,5 @@ NCVStatus ncvDrawRects_32u_device(Ncv32u *d_dst,
{
return drawRectsWrapperDevice(d_dst, dstStride, dstWidth, dstHeight, d_rects, numRects, color, cuStream);
}
#endif /* CUDA_DISABLER */

View File

@ -39,6 +39,7 @@
//
//M*/
#if !defined CUDA_DISABLER
#include <cuda_runtime.h>
#include <stdio.h>
@ -600,3 +601,5 @@ template class NCVImagePyramid<float3>;
template class NCVImagePyramid<float4>;
#endif //_WIN32
#endif /* CUDA_DISABLER */

View File

@ -46,7 +46,7 @@ using namespace cv;
using namespace cv::gpu;
using namespace std;
#if !defined (HAVE_CUDA)
#if !defined (HAVE_CUDA) || defined (CUDA_DISABLER)
void cv::gpu::BroxOpticalFlow::operator ()(const GpuMat&, const GpuMat&, GpuMat&, GpuMat&, Stream&) { throw_nogpu(); }
void cv::gpu::interpolateFrames(const GpuMat&, const GpuMat&, const GpuMat&, const GpuMat&, const GpuMat&, const GpuMat&, float, GpuMat&, GpuMat&, Stream&) { throw_nogpu(); }

View File

@ -54,7 +54,7 @@ using namespace std;
using namespace cv;
using namespace cv::gpu;
#if !defined(HAVE_CUDA)
#if !defined HAVE_CUDA || defined(CUDA_DISABLER)
void cv::gpu::FarnebackOpticalFlow::operator ()(const GpuMat&, const GpuMat&, GpuMat&, GpuMat&, Stream&) { throw_nogpu(); }

View File

@ -46,7 +46,7 @@ using namespace std;
using namespace cv;
using namespace cv::gpu;
#if !defined (HAVE_CUDA)
#if !defined (HAVE_CUDA) || defined (CUDA_DISABLER)
cv::gpu::ORB_GPU::ORB_GPU(int, float, int, int, int, int, int, int) : fastDetector_(20) { throw_nogpu(); }
void cv::gpu::ORB_GPU::operator()(const GpuMat&, const GpuMat&, std::vector<KeyPoint>&) { throw_nogpu(); }

View File

@ -42,7 +42,7 @@
#include "precomp.hpp"
#ifndef HAVE_CUDA
#if !defined HAVE_CUDA || defined(CUDA_DISABLER)
void cv::gpu::pyrDown(const GpuMat&, GpuMat&, Stream&) { throw_nogpu(); }
void cv::gpu::pyrUp(const GpuMat&, GpuMat&, Stream&) { throw_nogpu(); }

View File

@ -46,7 +46,7 @@ using namespace std;
using namespace cv;
using namespace cv::gpu;
#if !defined (HAVE_CUDA)
#if !defined (HAVE_CUDA) || defined (CUDA_DISABLER)
cv::gpu::PyrLKOpticalFlow::PyrLKOpticalFlow() { throw_nogpu(); }
void cv::gpu::PyrLKOpticalFlow::sparse(const GpuMat&, const GpuMat&, const GpuMat&, GpuMat&, GpuMat&, GpuMat*) { throw_nogpu(); }

View File

@ -42,7 +42,7 @@
#include "precomp.hpp"
#ifndef HAVE_CUDA
#if !defined HAVE_CUDA || defined(CUDA_DISABLER)
void cv::gpu::remap(const GpuMat&, GpuMat&, const GpuMat&, const GpuMat&, int, int, Scalar, Stream&){ throw_nogpu(); }

View File

@ -42,7 +42,7 @@
#include "precomp.hpp"
#ifndef HAVE_CUDA
#if !defined HAVE_CUDA || defined(CUDA_DISABLER)
void cv::gpu::resize(const GpuMat& src, GpuMat& dst, Size dsize, double fx, double fy, int interpolation, Stream& s)
{

View File

@ -46,7 +46,7 @@ using namespace cv;
using namespace cv::gpu;
using namespace std;
#if !defined (HAVE_CUDA)
#if !defined (HAVE_CUDA) || defined (CUDA_DISABLER)
void cv::gpu::merge(const GpuMat* /*src*/, size_t /*count*/, GpuMat& /*dst*/, Stream& /*stream*/) { throw_nogpu(); }
void cv::gpu::merge(const vector<GpuMat>& /*src*/, GpuMat& /*dst*/, Stream& /*stream*/) { throw_nogpu(); }

View File

@ -45,7 +45,7 @@
using namespace cv;
using namespace cv::gpu;
#if !defined (HAVE_CUDA)
#if !defined (HAVE_CUDA) || defined (CUDA_DISABLER)
cv::gpu::StereoBM_GPU::StereoBM_GPU() { throw_nogpu(); }
cv::gpu::StereoBM_GPU::StereoBM_GPU(int, int, int) { throw_nogpu(); }

View File

@ -46,7 +46,7 @@ using namespace cv;
using namespace cv::gpu;
using namespace std;
#if !defined (HAVE_CUDA)
#if !defined (HAVE_CUDA) || defined (CUDA_DISABLER)
void cv::gpu::StereoBeliefPropagation::estimateRecommendedParams(int, int, int&, int&, int&) { throw_nogpu(); }

View File

@ -46,7 +46,7 @@ using namespace cv;
using namespace cv::gpu;
using namespace std;
#if !defined (HAVE_CUDA)
#if !defined (HAVE_CUDA) || defined (CUDA_DISABLER)
void cv::gpu::StereoConstantSpaceBP::estimateRecommendedParams(int, int, int&, int&, int&, int&) { throw_nogpu(); }

View File

@ -46,7 +46,7 @@ using namespace cv;
using namespace cv::gpu;
using namespace std;
#if !defined (HAVE_CUDA)
#if !defined (HAVE_CUDA) || defined (CUDA_DISABLER)
cv::gpu::SURF_GPU::SURF_GPU() { throw_nogpu(); }
cv::gpu::SURF_GPU::SURF_GPU(double, int, int, bool, float, bool) { throw_nogpu(); }

View File

@ -42,7 +42,7 @@
#include "precomp.hpp"
#if !defined(HAVE_CUDA) || defined(__APPLE__)
#if !defined HAVE_CUDA || defined(CUDA_DISABLER) || defined(__APPLE__)
class cv::gpu::VideoReader_GPU::Impl
{

View File

@ -42,7 +42,7 @@
#include "precomp.hpp"
#if !defined(HAVE_CUDA) || !defined(WIN32)
#if !defined HAVE_CUDA || defined(CUDA_DISABLER) || !defined(WIN32)
class cv::gpu::VideoWriter_GPU::Impl
{

View File

@ -42,7 +42,7 @@
#include "precomp.hpp"
#ifndef HAVE_CUDA
#if !defined HAVE_CUDA || defined(CUDA_DISABLER)
void cv::gpu::warpAffine(const GpuMat&, GpuMat&, const Mat&, Size, int, int, Scalar, Stream&) { throw_nogpu(); }

View File

@ -74,7 +74,7 @@ void printOsInfo()
void printCudaInfo()
{
#ifndef HAVE_CUDA
#if !defined HAVE_CUDA || defined(CUDA_DISABLER)
cout << "OpenCV was built without CUDA support \n" << endl;
#else
int driver;

View File

@ -9,6 +9,8 @@
* agreement from NVIDIA Corporation is strictly prohibited.
*/
#if !defined CUDA_DISABLER
#include "TestCompact.h"
@ -127,3 +129,5 @@ bool TestCompact::deinit()
{
return true;
}
#endif /* CUDA_DISABLER */

Some files were not shown because too many files have changed in this diff Show More