diff --git a/modules/cudafeatures2d/CMakeLists.txt b/modules/cudafeatures2d/CMakeLists.txt new file mode 100644 index 000000000..9bca959f3 --- /dev/null +++ b/modules/cudafeatures2d/CMakeLists.txt @@ -0,0 +1,9 @@ +if(ANDROID OR IOS) + ocv_module_disable(cudafeatures2d) +endif() + +set(the_description "CUDA-accelerated Feature Detection and Description") + +ocv_warnings_disable(CMAKE_CXX_FLAGS /wd4127 /wd4100 /wd4324 /wd4512 /wd4515 -Wundef -Wmissing-declarations -Wshadow -Wunused-parameter) + +ocv_define_module(cudafeatures2d opencv_features2d opencv_cudafilters opencv_cudawarping) diff --git a/modules/gpufeatures2d/doc/gpufeatures2d.rst b/modules/cudafeatures2d/doc/cudafeatures2d.rst similarity index 100% rename from modules/gpufeatures2d/doc/gpufeatures2d.rst rename to modules/cudafeatures2d/doc/cudafeatures2d.rst diff --git a/modules/gpufeatures2d/doc/feature_detection_and_description.rst b/modules/cudafeatures2d/doc/feature_detection_and_description.rst similarity index 100% rename from modules/gpufeatures2d/doc/feature_detection_and_description.rst rename to modules/cudafeatures2d/doc/feature_detection_and_description.rst diff --git a/modules/gpufeatures2d/include/opencv2/gpufeatures2d.hpp b/modules/cudafeatures2d/include/opencv2/cudafeatures2d.hpp similarity index 98% rename from modules/gpufeatures2d/include/opencv2/gpufeatures2d.hpp rename to modules/cudafeatures2d/include/opencv2/cudafeatures2d.hpp index 6cd0bedce..16af28c4d 100644 --- a/modules/gpufeatures2d/include/opencv2/gpufeatures2d.hpp +++ b/modules/cudafeatures2d/include/opencv2/cudafeatures2d.hpp @@ -40,11 +40,11 @@ // //M*/ -#ifndef __OPENCV_GPUFEATURES2D_HPP__ -#define __OPENCV_GPUFEATURES2D_HPP__ +#ifndef __OPENCV_CUDAFEATURES2D_HPP__ +#define __OPENCV_CUDAFEATURES2D_HPP__ #ifndef __cplusplus -# error gpufeatures2d.hpp header must be compiled as C++ +# error cudafeatures2d.hpp header must be compiled as C++ #endif #include "opencv2/core/cuda.hpp" @@ -358,4 +358,4 @@ private: }} // namespace cv { namespace cuda { -#endif /* __OPENCV_GPUFEATURES2D_HPP__ */ +#endif /* __OPENCV_CUDAFEATURES2D_HPP__ */ diff --git a/modules/gpufeatures2d/perf/perf_features2d.cpp b/modules/cudafeatures2d/perf/perf_features2d.cpp similarity index 100% rename from modules/gpufeatures2d/perf/perf_features2d.cpp rename to modules/cudafeatures2d/perf/perf_features2d.cpp diff --git a/modules/gpufeatures2d/perf/perf_main.cpp b/modules/cudafeatures2d/perf/perf_main.cpp similarity index 98% rename from modules/gpufeatures2d/perf/perf_main.cpp rename to modules/cudafeatures2d/perf/perf_main.cpp index 5e7fb1b8b..07b891703 100644 --- a/modules/gpufeatures2d/perf/perf_main.cpp +++ b/modules/cudafeatures2d/perf/perf_main.cpp @@ -44,4 +44,4 @@ using namespace perf; -CV_PERF_TEST_CUDA_MAIN(gpufeatures2d) +CV_PERF_TEST_CUDA_MAIN(cudafeatures2d) diff --git a/modules/gpufeatures2d/perf/perf_precomp.cpp b/modules/cudafeatures2d/perf/perf_precomp.cpp similarity index 100% rename from modules/gpufeatures2d/perf/perf_precomp.cpp rename to modules/cudafeatures2d/perf/perf_precomp.cpp diff --git a/modules/gpufeatures2d/perf/perf_precomp.hpp b/modules/cudafeatures2d/perf/perf_precomp.hpp similarity index 98% rename from modules/gpufeatures2d/perf/perf_precomp.hpp rename to modules/cudafeatures2d/perf/perf_precomp.hpp index 4f767c4fb..1ec469013 100644 --- a/modules/gpufeatures2d/perf/perf_precomp.hpp +++ b/modules/cudafeatures2d/perf/perf_precomp.hpp @@ -54,7 +54,7 @@ #include "opencv2/ts.hpp" #include "opencv2/ts/gpu_perf.hpp" -#include "opencv2/gpufeatures2d.hpp" +#include "opencv2/cudafeatures2d.hpp" #include "opencv2/features2d.hpp" #ifdef GTEST_CREATE_SHARED_LIBRARY diff --git a/modules/gpufeatures2d/src/brute_force_matcher.cpp b/modules/cudafeatures2d/src/brute_force_matcher.cpp similarity index 100% rename from modules/gpufeatures2d/src/brute_force_matcher.cpp rename to modules/cudafeatures2d/src/brute_force_matcher.cpp diff --git a/modules/gpufeatures2d/src/cuda/bf_knnmatch.cu b/modules/cudafeatures2d/src/cuda/bf_knnmatch.cu similarity index 100% rename from modules/gpufeatures2d/src/cuda/bf_knnmatch.cu rename to modules/cudafeatures2d/src/cuda/bf_knnmatch.cu diff --git a/modules/gpufeatures2d/src/cuda/bf_match.cu b/modules/cudafeatures2d/src/cuda/bf_match.cu similarity index 100% rename from modules/gpufeatures2d/src/cuda/bf_match.cu rename to modules/cudafeatures2d/src/cuda/bf_match.cu diff --git a/modules/gpufeatures2d/src/cuda/bf_radius_match.cu b/modules/cudafeatures2d/src/cuda/bf_radius_match.cu similarity index 100% rename from modules/gpufeatures2d/src/cuda/bf_radius_match.cu rename to modules/cudafeatures2d/src/cuda/bf_radius_match.cu diff --git a/modules/gpufeatures2d/src/cuda/fast.cu b/modules/cudafeatures2d/src/cuda/fast.cu similarity index 100% rename from modules/gpufeatures2d/src/cuda/fast.cu rename to modules/cudafeatures2d/src/cuda/fast.cu diff --git a/modules/gpufeatures2d/src/cuda/orb.cu b/modules/cudafeatures2d/src/cuda/orb.cu similarity index 100% rename from modules/gpufeatures2d/src/cuda/orb.cu rename to modules/cudafeatures2d/src/cuda/orb.cu diff --git a/modules/gpufeatures2d/src/fast.cpp b/modules/cudafeatures2d/src/fast.cpp similarity index 100% rename from modules/gpufeatures2d/src/fast.cpp rename to modules/cudafeatures2d/src/fast.cpp diff --git a/modules/gpufeatures2d/src/orb.cpp b/modules/cudafeatures2d/src/orb.cpp similarity index 100% rename from modules/gpufeatures2d/src/orb.cpp rename to modules/cudafeatures2d/src/orb.cpp diff --git a/modules/gpufeatures2d/src/precomp.cpp b/modules/cudafeatures2d/src/precomp.cpp similarity index 100% rename from modules/gpufeatures2d/src/precomp.cpp rename to modules/cudafeatures2d/src/precomp.cpp diff --git a/modules/gpufeatures2d/src/precomp.hpp b/modules/cudafeatures2d/src/precomp.hpp similarity index 98% rename from modules/gpufeatures2d/src/precomp.hpp rename to modules/cudafeatures2d/src/precomp.hpp index 9aedd2bd7..da64ba4a1 100644 --- a/modules/gpufeatures2d/src/precomp.hpp +++ b/modules/cudafeatures2d/src/precomp.hpp @@ -47,7 +47,7 @@ #include #include -#include "opencv2/gpufeatures2d.hpp" +#include "opencv2/cudafeatures2d.hpp" #include "opencv2/cudaarithm.hpp" #include "opencv2/cudawarping.hpp" #include "opencv2/features2d.hpp" diff --git a/modules/gpufeatures2d/test/test_features2d.cpp b/modules/cudafeatures2d/test/test_features2d.cpp similarity index 100% rename from modules/gpufeatures2d/test/test_features2d.cpp rename to modules/cudafeatures2d/test/test_features2d.cpp diff --git a/modules/gpufeatures2d/test/test_main.cpp b/modules/cudafeatures2d/test/test_main.cpp similarity index 100% rename from modules/gpufeatures2d/test/test_main.cpp rename to modules/cudafeatures2d/test/test_main.cpp diff --git a/modules/gpufeatures2d/test/test_precomp.cpp b/modules/cudafeatures2d/test/test_precomp.cpp similarity index 100% rename from modules/gpufeatures2d/test/test_precomp.cpp rename to modules/cudafeatures2d/test/test_precomp.cpp diff --git a/modules/gpufeatures2d/test/test_precomp.hpp b/modules/cudafeatures2d/test/test_precomp.hpp similarity index 98% rename from modules/gpufeatures2d/test/test_precomp.hpp rename to modules/cudafeatures2d/test/test_precomp.hpp index 4ce8f7849..4063b8fea 100644 --- a/modules/gpufeatures2d/test/test_precomp.hpp +++ b/modules/cudafeatures2d/test/test_precomp.hpp @@ -54,7 +54,7 @@ #include "opencv2/ts.hpp" #include "opencv2/ts/gpu_test.hpp" -#include "opencv2/gpufeatures2d.hpp" +#include "opencv2/cudafeatures2d.hpp" #include "opencv2/features2d.hpp" #include "cvconfig.h" diff --git a/modules/gpufeatures2d/CMakeLists.txt b/modules/gpufeatures2d/CMakeLists.txt deleted file mode 100644 index c4e57a4a9..000000000 --- a/modules/gpufeatures2d/CMakeLists.txt +++ /dev/null @@ -1,9 +0,0 @@ -if(ANDROID OR IOS) - ocv_module_disable(gpufeatures2d) -endif() - -set(the_description "GPU-accelerated Feature Detection and Description") - -ocv_warnings_disable(CMAKE_CXX_FLAGS /wd4127 /wd4100 /wd4324 /wd4512 /wd4515 -Wundef -Wmissing-declarations -Wshadow -Wunused-parameter) - -ocv_define_module(gpufeatures2d opencv_features2d opencv_cudafilters opencv_cudawarping) diff --git a/modules/stitching/CMakeLists.txt b/modules/stitching/CMakeLists.txt index 9e9158a99..87ac5c325 100644 --- a/modules/stitching/CMakeLists.txt +++ b/modules/stitching/CMakeLists.txt @@ -1,3 +1,3 @@ set(the_description "Images stitching") ocv_define_module(stitching opencv_imgproc opencv_features2d opencv_calib3d opencv_objdetect - OPTIONAL opencv_gpu opencv_cudaarithm opencv_cudafilters opencv_gpufeatures2d opencv_nonfree) + OPTIONAL opencv_gpu opencv_cudaarithm opencv_cudafilters opencv_cudafeatures2d opencv_nonfree) diff --git a/modules/stitching/src/matchers.cpp b/modules/stitching/src/matchers.cpp index aee004e8d..cf3cbd4b3 100644 --- a/modules/stitching/src/matchers.cpp +++ b/modules/stitching/src/matchers.cpp @@ -125,7 +125,7 @@ private: float match_conf_; }; -#ifdef HAVE_OPENCV_GPUFEATURES2D +#ifdef HAVE_OPENCV_CUDAFEATURES2D class GpuMatcher : public FeaturesMatcher { public: @@ -200,7 +200,7 @@ void CpuMatcher::match(const ImageFeatures &features1, const ImageFeatures &feat LOG("1->2 & 2->1 matches: " << matches_info.matches.size() << endl); } -#ifdef HAVE_OPENCV_GPUFEATURES2D +#ifdef HAVE_OPENCV_CUDAFEATURES2D void GpuMatcher::match(const ImageFeatures &features1, const ImageFeatures &features2, MatchesInfo& matches_info) { matches_info.matches.clear(); @@ -531,7 +531,7 @@ BestOf2NearestMatcher::BestOf2NearestMatcher(bool try_use_gpu, float match_conf, { (void)try_use_gpu; -#ifdef HAVE_OPENCV_GPUFEATURES2D +#ifdef HAVE_OPENCV_CUDAFEATURES2D if (try_use_gpu && getCudaEnabledDeviceCount() > 0) { impl_ = new GpuMatcher(match_conf); diff --git a/modules/stitching/src/precomp.hpp b/modules/stitching/src/precomp.hpp index c23ede0c5..b18bcf456 100644 --- a/modules/stitching/src/precomp.hpp +++ b/modules/stitching/src/precomp.hpp @@ -76,8 +76,8 @@ # include "opencv2/cudawarping.hpp" #endif -#ifdef HAVE_OPENCV_GPUFEATURES2D -# include "opencv2/gpufeatures2d.hpp" +#ifdef HAVE_OPENCV_CUDAFEATURES2D +# include "opencv2/cudafeatures2d.hpp" #endif #ifdef HAVE_OPENCV_GPU diff --git a/samples/gpu/CMakeLists.txt b/samples/gpu/CMakeLists.txt index abf80565f..c74531b4d 100644 --- a/samples/gpu/CMakeLists.txt +++ b/samples/gpu/CMakeLists.txt @@ -3,7 +3,7 @@ SET(OPENCV_GPU_SAMPLES_REQUIRED_DEPS opencv_core opencv_flann opencv_imgproc ope opencv_calib3d opencv_legacy opencv_contrib opencv_gpu opencv_nonfree opencv_softcascade opencv_superres opencv_cudaarithm opencv_cudafilters opencv_cudawarping opencv_cudaimgproc - opencv_gpufeatures2d opencv_cudaoptflow opencv_gpubgsegm + opencv_cudafeatures2d opencv_cudaoptflow opencv_gpubgsegm opencv_cudastereo opencv_cudalegacy) ocv_check_dependencies(${OPENCV_GPU_SAMPLES_REQUIRED_DEPS}) diff --git a/samples/gpu/performance/tests.cpp b/samples/gpu/performance/tests.cpp index 0498b07ea..70f3aaf9f 100644 --- a/samples/gpu/performance/tests.cpp +++ b/samples/gpu/performance/tests.cpp @@ -7,7 +7,7 @@ #include "opencv2/cudaimgproc.hpp" #include "opencv2/cudaarithm.hpp" #include "opencv2/cudawarping.hpp" -#include "opencv2/gpufeatures2d.hpp" +#include "opencv2/cudafeatures2d.hpp" #include "opencv2/cudafilters.hpp" #include "opencv2/cudaoptflow.hpp" #include "opencv2/gpubgsegm.hpp" diff --git a/samples/gpu/surf_keypoint_matcher.cpp b/samples/gpu/surf_keypoint_matcher.cpp index a05bfe4b5..5e68b3fbd 100644 --- a/samples/gpu/surf_keypoint_matcher.cpp +++ b/samples/gpu/surf_keypoint_matcher.cpp @@ -7,7 +7,7 @@ #include "opencv2/core/core.hpp" #include "opencv2/features2d/features2d.hpp" #include "opencv2/highgui/highgui.hpp" -#include "opencv2/gpufeatures2d.hpp" +#include "opencv2/cudafeatures2d.hpp" #include "opencv2/nonfree/gpu.hpp" using namespace std;