From ad5cddc0079f2086db6f7b9400e2a740bdd3a054 Mon Sep 17 00:00:00 2001 From: Andrey Kamaev Date: Wed, 13 Mar 2013 16:22:44 +0400 Subject: [PATCH] Main module headers are moved 1 level up e.g. become Also renamed to --- apps/CMakeLists.txt | 2 ++ apps/haartraining/_cvcommon.h | 2 +- apps/haartraining/performance.cpp | 2 +- apps/sft/dataset.cpp | 4 ++-- apps/sft/include/sft/common.hpp | 4 ++-- apps/traincascade/HOGfeatures.cpp | 2 +- apps/traincascade/boost.cpp | 2 +- apps/traincascade/cascadeclassifier.cpp | 2 +- apps/traincascade/features.cpp | 2 +- apps/traincascade/haarfeatures.cpp | 2 +- apps/traincascade/imagestorage.cpp | 2 +- apps/traincascade/lbpfeatures.cpp | 2 +- apps/traincascade/traincascade.cpp | 2 +- cmake/OpenCVModule.cmake | 2 +- doc/check_docs.py | 14 ++++++------ .../interoperability_with_OpenCV_1.rst | 6 ++--- .../feature_description.rst | 8 +++---- .../feature_detection/feature_detection.rst | 6 ++--- .../feature_flann_matcher.rst | 6 ++--- .../feature_homography/feature_homography.rst | 8 +++---- .../corner_subpixeles/corner_subpixeles.rst | 4 ++-- .../good_features_to_track.rst | 4 ++-- .../harris_detector/harris_detector.rst | 4 ++-- .../gpu-basics-similarity.rst | 2 +- .../erosion_dilatation/erosion_dilatation.rst | 4 ++-- .../gausian_median_blur_bilateral_filter.rst | 4 ++-- .../back_projection/back_projection.rst | 4 ++-- .../histogram_calculation.rst | 4 ++-- .../histogram_comparison.rst | 4 ++-- .../histogram_equalization.rst | 4 ++-- .../template_matching/template_matching.rst | 4 ++-- .../canny_detector/canny_detector.rst | 4 ++-- .../copyMakeBorder/copyMakeBorder.rst | 4 ++-- .../imgproc/imgtrans/filter_2d/filter_2d.rst | 4 ++-- .../imgtrans/hough_circle/hough_circle.rst | 4 ++-- .../imgtrans/hough_lines/hough_lines.rst | 4 ++-- .../laplace_operator/laplace_operator.rst | 4 ++-- .../imgproc/imgtrans/remap/remap.rst | 4 ++-- .../sobel_derivatives/sobel_derivatives.rst | 4 ++-- .../imgtrans/warp_affine/warp_affine.rst | 4 ++-- .../opening_closing_hats.rst | 4 ++-- doc/tutorials/imgproc/pyramids/pyramids.rst | 4 ++-- .../bounding_rects_circles.rst | 4 ++-- .../bounding_rotated_ellipses.rst | 4 ++-- .../find_contours/find_contours.rst | 4 ++-- .../imgproc/shapedescriptors/hull/hull.rst | 4 ++-- .../shapedescriptors/moments/moments.rst | 4 ++-- .../point_polygon_test/point_polygon_test.rst | 4 ++-- doc/tutorials/imgproc/threshold/threshold.rst | 4 ++-- .../cascade_classifier/cascade_classifier.rst | 6 ++--- include/opencv/cv.h | 14 ++++++------ include/opencv/cvaux.h | 17 +++++++------- include/opencv/cxcore.h | 2 +- include/opencv/highgui.h | 4 ++-- include/opencv/ml.h | 4 ++-- include/opencv2/opencv.hpp | 20 ++++++++--------- modules/CMakeLists.txt | 2 ++ .../androidcamera/include/camera_activity.hpp | 1 - .../include/opencv2/{calib3d => }/calib3d.hpp | 22 +++++++++---------- modules/calib3d/perf/perf_precomp.hpp | 8 +++---- modules/calib3d/src/calibinit.cpp | 2 +- modules/calib3d/src/checkchessboard.cpp | 2 +- modules/calib3d/src/circlesgrid.cpp | 2 +- modules/calib3d/src/precomp.hpp | 6 ++--- .../calib3d/test/test_chessboardgenerator.hpp | 2 +- modules/calib3d/test/test_precomp.hpp | 8 +++---- modules/contrib/doc/facerec/colormaps.rst | 6 ++--- .../contrib/doc/facerec/src/facerec_demo.cpp | 6 ++--- .../doc/facerec/src/facerec_eigenfaces.cpp | 6 ++--- .../doc/facerec/src/facerec_fisherfaces.cpp | 6 ++--- .../contrib/doc/facerec/src/facerec_lbph.cpp | 6 ++--- .../doc/facerec/src/facerec_save_load.cpp | 6 ++--- .../contrib/doc/facerec/src/facerec_video.cpp | 10 ++++----- .../include/opencv2/{contrib => }/contrib.hpp | 9 ++++---- .../contrib/detection_based_tracker.hpp | 4 ++-- .../include/opencv2/contrib/hybridtracker.hpp | 9 ++++---- .../include/opencv2/contrib/openfabmap.hpp | 4 ++-- .../include/opencv2/contrib/retina.hpp | 2 +- modules/contrib/src/ba.cpp | 2 +- modules/contrib/src/chamfermatching.cpp | 2 +- modules/contrib/src/featuretracker.cpp | 2 +- modules/contrib/src/gencolors.cpp | 1 - modules/contrib/src/inputoutput.cpp | 2 +- modules/contrib/src/precomp.hpp | 8 +++---- modules/contrib/src/rgbdodometry.cpp | 6 ++--- modules/contrib/test/test_precomp.hpp | 4 ++-- modules/core/doc/basic_structures.rst | 2 +- modules/core/doc/intro.rst | 4 ++-- .../core/include/opencv2/{core => }/core.hpp | 4 ++-- modules/core/include/opencv2/core/eigen.hpp | 2 +- modules/core/include/opencv2/core/gpumat.hpp | 2 +- .../core/{opengl_interop.hpp => opengl.hpp} | 2 +- modules/core/perf/perf_precomp.hpp | 2 +- modules/core/src/gl_core_3_1.cpp | 2 +- modules/core/src/matrix.cpp | 2 +- modules/core/src/opengl_interop.cpp | 2 +- modules/core/src/precomp.hpp | 2 +- modules/core/test/test_precomp.hpp | 2 +- .../opencv2/{features2d => }/features2d.hpp | 2 +- modules/features2d/perf/perf_precomp.hpp | 6 ++--- modules/features2d/src/blobdetector.cpp | 2 +- modules/features2d/src/brisk.cpp | 6 ++--- modules/features2d/src/precomp.hpp | 4 ++-- .../test/test_descriptors_regression.cpp | 2 +- .../test/test_detectors_regression.cpp | 2 +- modules/features2d/test/test_keypoints.cpp | 2 +- .../test/test_matchers_algorithmic.cpp | 2 +- modules/features2d/test/test_orb.cpp | 2 +- modules/features2d/test/test_precomp.hpp | 8 +++---- .../test_rotation_and_scale_invariance.cpp | 2 +- .../include/opencv2/{flann => }/flann.hpp | 2 +- .../flann/include/opencv2/flann/miniflann.hpp | 2 +- modules/flann/include/opencv2/flann/timer.h | 2 +- modules/flann/src/flann.cpp | 2 +- modules/flann/src/precomp.hpp | 2 +- modules/flann/test/test_precomp.hpp | 6 ++--- modules/gpu/CMakeLists.txt | 2 +- modules/gpu/app/nv_perf_test/main.cpp | 13 +++++------ modules/gpu/include/opencv2/{gpu => }/gpu.hpp | 6 ++--- .../include/opencv2/gpu/stream_accessor.hpp | 2 +- modules/gpu/perf/perf_precomp.hpp | 21 +++++++++--------- modules/gpu/perf/utility.hpp | 4 ++-- modules/gpu/perf4au/main.cpp | 13 +++++------ modules/gpu/src/precomp.hpp | 8 +++---- modules/gpu/test/interpolation.hpp | 4 ++-- .../gpu/test/nvidia/NCVTestSourceProvider.hpp | 2 +- modules/gpu/test/test_precomp.hpp | 21 +++++++++--------- modules/gpu/test/utility.hpp | 7 +++--- modules/highgui/CMakeLists.txt | 2 +- .../include/opencv2/{highgui => }/highgui.hpp | 2 +- .../highgui/include/opencv2/highgui/cap_ios.h | 2 +- modules/highgui/perf/perf_precomp.hpp | 4 ++-- modules/highgui/src/cap_android.cpp | 2 +- modules/highgui/src/cap_avfoundation.mm | 2 +- modules/highgui/src/cap_ffmpeg_impl.hpp | 2 +- modules/highgui/src/cap_openni.cpp | 4 ++-- modules/highgui/src/cap_qtkit.mm | 2 +- modules/highgui/src/grfmt_webp.cpp | 2 +- modules/highgui/src/precomp.hpp | 2 +- modules/highgui/src/window.cpp | 2 +- modules/highgui/src/window_w32.cpp | 2 +- modules/highgui/test/test_drawing.cpp | 2 +- modules/highgui/test/test_ffmpeg.cpp | 2 +- modules/highgui/test/test_fourcc.cpp | 2 +- modules/highgui/test/test_framecount.cpp | 2 +- modules/highgui/test/test_grfmt.cpp | 2 +- modules/highgui/test/test_gui.cpp | 2 +- modules/highgui/test/test_positioning.cpp | 2 +- modules/highgui/test/test_precomp.hpp | 4 ++-- modules/highgui/test/test_video_io.cpp | 2 +- modules/highgui/test/test_video_pos.cpp | 2 +- .../include/opencv2/{imgproc => }/imgproc.hpp | 2 +- modules/imgproc/perf/perf_precomp.hpp | 6 ++--- modules/imgproc/src/precomp.hpp | 2 +- modules/imgproc/test/test_precomp.hpp | 6 ++--- modules/java/generator/config/core.filelist | 2 +- modules/java/generator/gen_java.py | 2 +- modules/java/generator/src/cpp/Mat.cpp | 2 +- .../java/generator/src/cpp/VideoCapture.cpp | 2 +- modules/java/generator/src/cpp/converters.h | 2 +- .../java/generator/src/cpp/core_manual.hpp | 2 +- .../generator/src/cpp/features2d_manual.hpp | 2 +- modules/java/generator/src/cpp/jni_part.cpp | 10 ++++----- modules/java/generator/src/cpp/utils.cpp | 4 ++-- .../include/opencv2/{legacy => }/legacy.hpp | 8 +++---- modules/legacy/src/oneway.cpp | 2 +- modules/legacy/src/precomp.hpp | 5 ++--- modules/legacy/test/test_precomp.hpp | 8 +++---- modules/ml/include/opencv2/{ml => }/ml.hpp | 4 ++-- modules/ml/src/precomp.hpp | 2 +- modules/ml/test/test_precomp.hpp | 4 ++-- .../include/opencv2/{nonfree => }/nonfree.hpp | 0 .../include/opencv2/nonfree/features2d.hpp | 2 +- modules/nonfree/perf/perf_precomp.hpp | 6 ++--- modules/nonfree/src/precomp.hpp | 4 ++-- modules/nonfree/test/test_features2d.cpp | 2 +- modules/nonfree/test/test_keypoints.cpp | 2 +- modules/nonfree/test/test_precomp.hpp | 8 +++---- .../test_rotation_and_scale_invariance.cpp | 2 +- .../opencv2/{objdetect => }/objdetect.hpp | 2 +- .../objdetect/perf/perf_cascadeclassifier.cpp | 2 +- modules/objdetect/perf/perf_precomp.hpp | 6 ++--- modules/objdetect/src/datamatrix.cpp | 2 +- modules/objdetect/src/precomp.hpp | 6 ++--- modules/objdetect/test/test_cascadeandhog.cpp | 2 +- modules/objdetect/test/test_precomp.hpp | 8 +++---- modules/ocl/include/opencv2/{ocl => }/ocl.hpp | 8 +++---- modules/ocl/perf/perf_haar.cpp | 1 - modules/ocl/perf/perf_pyrup.cpp | 1 - modules/ocl/perf/precomp.hpp | 16 +++++++------- modules/ocl/src/precomp.hpp | 6 ++--- modules/ocl/src/surf.cpp | 1 - modules/ocl/test/precomp.hpp | 16 +++++++------- modules/ocl/test/test_haar.cpp | 2 +- modules/ocl/test/test_hog.cpp | 2 +- modules/ocl/test/test_pyrup.cpp | 1 - .../include/opencv2/{photo => }/photo.hpp | 4 ++-- modules/photo/perf/perf_precomp.hpp | 6 ++--- modules/photo/src/denoising.cpp | 4 ++-- .../src/fast_nlmeans_denoising_invoker.hpp | 4 ++-- ...fast_nlmeans_denoising_invoker_commons.hpp | 4 ++-- .../fast_nlmeans_multi_denoising_invoker.hpp | 4 ++-- modules/photo/src/precomp.hpp | 2 +- modules/photo/test/test_denoising.cpp | 2 +- modules/photo/test/test_precomp.hpp | 6 ++--- modules/python/CMakeLists.txt | 22 +++++++++---------- modules/python/src2/cv2.cpp | 22 +++++++++---------- modules/python/src2/cv2.cv.hpp | 12 +++++----- modules/python/src2/hdr_parser.py | 16 +++++++------- .../opencv2/{softcascade => }/softcascade.hpp | 2 +- modules/softcascade/perf/perf_precomp.hpp | 6 ++--- modules/softcascade/perf/perf_softcascade.cpp | 2 +- modules/softcascade/src/precomp.hpp | 6 ++--- modules/softcascade/test/test_precomp.hpp | 8 +++---- .../{stitching/stitcher.hpp => stitching.hpp} | 4 ++-- .../opencv2/stitching/detail/autocalib.hpp | 2 +- .../opencv2/stitching/detail/blenders.hpp | 2 +- .../opencv2/stitching/detail/camera.hpp | 2 +- .../stitching/detail/exposure_compensate.hpp | 2 +- .../opencv2/stitching/detail/matchers.hpp | 6 ++--- .../stitching/detail/motion_estimators.hpp | 2 +- .../opencv2/stitching/detail/seam_finders.hpp | 2 +- .../include/opencv2/stitching/detail/util.hpp | 2 +- .../opencv2/stitching/detail/util_inl.hpp | 2 +- .../opencv2/stitching/detail/warpers.hpp | 6 ++--- .../opencv2/stitching/detail/warpers_inl.hpp | 2 +- modules/stitching/perf/perf_precomp.hpp | 5 ++--- modules/stitching/perf/perf_stich.cpp | 4 ++-- modules/stitching/src/matchers.cpp | 2 +- modules/stitching/src/precomp.hpp | 12 +++++----- modules/stitching/test/test_precomp.hpp | 6 ++--- modules/ts/include/opencv2/{ts => }/ts.hpp | 4 ++-- modules/ts/include/opencv2/ts/ts_perf.hpp | 4 ++-- modules/ts/src/precomp.hpp | 2 +- .../motion_analysis_and_object_tracking.rst | 3 +-- .../include/opencv2/{video => }/video.hpp | 0 .../include/opencv2/video/background_segm.hpp | 2 +- .../video/include/opencv2/video/tracking.hpp | 4 ++-- modules/video/perf/perf_precomp.hpp | 8 +++---- modules/video/src/video_init.cpp | 2 +- modules/video/test/test_precomp.hpp | 9 ++++---- .../opencv2/{videostab => }/videostab.hpp | 0 .../include/opencv2/videostab/deblurring.hpp | 2 +- .../opencv2/videostab/fast_marching.hpp | 2 +- .../opencv2/videostab/frame_source.hpp | 2 +- .../opencv2/videostab/global_motion.hpp | 6 ++--- .../include/opencv2/videostab/inpainting.hpp | 4 ++-- .../include/opencv2/videostab/log.hpp | 2 +- .../include/opencv2/videostab/motion_core.hpp | 2 +- .../opencv2/videostab/motion_stabilizing.hpp | 2 +- .../opencv2/videostab/optical_flow.hpp | 4 ++-- .../opencv2/videostab/outlier_rejection.hpp | 2 +- .../include/opencv2/videostab/ring_buffer.hpp | 2 +- .../include/opencv2/videostab/stabilizer.hpp | 4 ++-- .../opencv2/videostab/wobble_suppression.hpp | 4 ++-- modules/videostab/src/frame_source.cpp | 2 +- modules/videostab/src/optical_flow.cpp | 2 +- modules/videostab/src/outlier_rejection.cpp | 1 - modules/videostab/src/precomp.hpp | 10 ++++----- .../include/opencv2/{world => }/world.hpp | 2 +- modules/world/src/precomp.hpp | 10 ++++----- samples/cpp/stitching.cpp | 4 ++-- samples/cpp/videostab.cpp | 10 ++++----- samples/gpu/alpha_comp.cpp | 2 +- samples/gpu/opengl.cpp | 2 +- samples/gpu/video_reader.cpp | 2 +- 266 files changed, 571 insertions(+), 588 deletions(-) rename modules/calib3d/include/opencv2/{calib3d => }/calib3d.hpp (98%) rename modules/contrib/include/opencv2/{contrib => }/contrib.hpp (99%) rename modules/core/include/opencv2/{core => }/core.hpp (99%) rename modules/core/include/opencv2/core/{opengl_interop.hpp => opengl.hpp} (99%) rename modules/features2d/include/opencv2/{features2d => }/features2d.hpp (99%) rename modules/flann/include/opencv2/{flann => }/flann.hpp (99%) rename modules/gpu/include/opencv2/{gpu => }/gpu.hpp (99%) rename modules/highgui/include/opencv2/{highgui => }/highgui.hpp (99%) rename modules/imgproc/include/opencv2/{imgproc => }/imgproc.hpp (99%) rename modules/legacy/include/opencv2/{legacy => }/legacy.hpp (99%) rename modules/ml/include/opencv2/{ml => }/ml.hpp (99%) rename modules/nonfree/include/opencv2/{nonfree => }/nonfree.hpp (100%) rename modules/objdetect/include/opencv2/{objdetect => }/objdetect.hpp (99%) rename modules/ocl/include/opencv2/{ocl => }/ocl.hpp (99%) rename modules/photo/include/opencv2/{photo => }/photo.hpp (98%) rename modules/softcascade/include/opencv2/{softcascade => }/softcascade.hpp (99%) rename modules/stitching/include/opencv2/{stitching/stitcher.hpp => stitching.hpp} (98%) rename modules/ts/include/opencv2/{ts => }/ts.hpp (99%) rename modules/video/include/opencv2/{video => }/video.hpp (100%) rename modules/videostab/include/opencv2/{videostab => }/videostab.hpp (100%) rename modules/world/include/opencv2/{world => }/world.hpp (98%) diff --git a/apps/CMakeLists.txt b/apps/CMakeLists.txt index a5db31fe5a..4652d9229c 100644 --- a/apps/CMakeLists.txt +++ b/apps/CMakeLists.txt @@ -1,3 +1,5 @@ +add_definition(-D__OPENCV_BUILD=1) + add_subdirectory(haartraining) add_subdirectory(traincascade) add_subdirectory(sft) diff --git a/apps/haartraining/_cvcommon.h b/apps/haartraining/_cvcommon.h index e4f1081645..5b363f1fce 100644 --- a/apps/haartraining/_cvcommon.h +++ b/apps/haartraining/_cvcommon.h @@ -42,7 +42,7 @@ #ifndef __CVCOMMON_H_ #define __CVCOMMON_H_ -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" #include "opencv2/core/internal.hpp" #include "cxcore.h" diff --git a/apps/haartraining/performance.cpp b/apps/haartraining/performance.cpp index 2fe98f8211..0620f21a1b 100644 --- a/apps/haartraining/performance.cpp +++ b/apps/haartraining/performance.cpp @@ -44,7 +44,7 @@ * * Measure performance of classifier */ -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" #include "opencv2/core/internal.hpp" #include "cv.h" diff --git a/apps/sft/dataset.cpp b/apps/sft/dataset.cpp index d89a38e888..dd4ba5999f 100644 --- a/apps/sft/dataset.cpp +++ b/apps/sft/dataset.cpp @@ -41,7 +41,7 @@ //M*/ #include -#include +#include #include #include @@ -74,4 +74,4 @@ int sft::ScaledDataset::available(SampleType type) const return (int)((type == POSITIVE)? pos.size():neg.size()); } -sft::ScaledDataset::~ScaledDataset(){} \ No newline at end of file +sft::ScaledDataset::~ScaledDataset(){} diff --git a/apps/sft/include/sft/common.hpp b/apps/sft/include/sft/common.hpp index 6f020ee684..93439a48ed 100644 --- a/apps/sft/include/sft/common.hpp +++ b/apps/sft/include/sft/common.hpp @@ -43,8 +43,8 @@ #ifndef __SFT_COMMON_HPP__ #define __SFT_COMMON_HPP__ -#include -#include +#include +#include namespace cv {using namespace softcascade;} namespace sft diff --git a/apps/traincascade/HOGfeatures.cpp b/apps/traincascade/HOGfeatures.cpp index 8bbdee609c..eaf4bd7960 100644 --- a/apps/traincascade/HOGfeatures.cpp +++ b/apps/traincascade/HOGfeatures.cpp @@ -1,4 +1,4 @@ -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" #include "opencv2/core/internal.hpp" #include "HOGfeatures.h" diff --git a/apps/traincascade/boost.cpp b/apps/traincascade/boost.cpp index ea12c194e7..1b0f390a5b 100644 --- a/apps/traincascade/boost.cpp +++ b/apps/traincascade/boost.cpp @@ -1,4 +1,4 @@ -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" #include "opencv2/core/internal.hpp" #include "boost.h" diff --git a/apps/traincascade/cascadeclassifier.cpp b/apps/traincascade/cascadeclassifier.cpp index 66f6876918..f6752da0c9 100644 --- a/apps/traincascade/cascadeclassifier.cpp +++ b/apps/traincascade/cascadeclassifier.cpp @@ -1,4 +1,4 @@ -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" #include "opencv2/core/internal.hpp" #include "cascadeclassifier.h" diff --git a/apps/traincascade/features.cpp b/apps/traincascade/features.cpp index 9629509f38..4aebc80940 100644 --- a/apps/traincascade/features.cpp +++ b/apps/traincascade/features.cpp @@ -1,4 +1,4 @@ -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" #include "opencv2/core/internal.hpp" #include "traincascade_features.h" diff --git a/apps/traincascade/haarfeatures.cpp b/apps/traincascade/haarfeatures.cpp index 9f8bce0832..59f1fd4ca7 100644 --- a/apps/traincascade/haarfeatures.cpp +++ b/apps/traincascade/haarfeatures.cpp @@ -1,4 +1,4 @@ -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" #include "opencv2/core/internal.hpp" #include "haarfeatures.h" diff --git a/apps/traincascade/imagestorage.cpp b/apps/traincascade/imagestorage.cpp index 9faf84aa0a..e7922a9afc 100644 --- a/apps/traincascade/imagestorage.cpp +++ b/apps/traincascade/imagestorage.cpp @@ -1,4 +1,4 @@ -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" #include "opencv2/core/internal.hpp" #include "cv.h" diff --git a/apps/traincascade/lbpfeatures.cpp b/apps/traincascade/lbpfeatures.cpp index cf9bb7b245..5e23d9e461 100644 --- a/apps/traincascade/lbpfeatures.cpp +++ b/apps/traincascade/lbpfeatures.cpp @@ -1,4 +1,4 @@ -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" #include "opencv2/core/internal.hpp" #include "lbpfeatures.h" diff --git a/apps/traincascade/traincascade.cpp b/apps/traincascade/traincascade.cpp index dfb49b5078..c85046e6b7 100644 --- a/apps/traincascade/traincascade.cpp +++ b/apps/traincascade/traincascade.cpp @@ -1,4 +1,4 @@ -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" #include "opencv2/core/internal.hpp" #include "cv.h" diff --git a/cmake/OpenCVModule.cmake b/cmake/OpenCVModule.cmake index bac3fe397d..48aa7139a2 100644 --- a/cmake/OpenCVModule.cmake +++ b/cmake/OpenCVModule.cmake @@ -429,7 +429,7 @@ endmacro() macro(ocv_glob_module_sources) file(GLOB lib_srcs "src/*.cpp") file(GLOB lib_int_hdrs "src/*.hpp" "src/*.h") - file(GLOB lib_hdrs "include/opencv2/${name}/*.hpp" "include/opencv2/${name}/*.h") + file(GLOB lib_hdrs "include/opencv2/*.hpp" "include/opencv2/${name}/*.hpp" "include/opencv2/${name}/*.h") file(GLOB lib_hdrs_detail "include/opencv2/${name}/detail/*.hpp" "include/opencv2/${name}/detail/*.h") file(GLOB lib_device_srcs "src/cuda/*.cu") diff --git a/doc/check_docs.py b/doc/check_docs.py index 2d8799341d..487b390e8a 100755 --- a/doc/check_docs.py +++ b/doc/check_docs.py @@ -6,15 +6,15 @@ sys.path.append("../modules/python/src2/") import hdr_parser as hp opencv_hdr_list = [ -"../modules/core/include/opencv2/core/core.hpp", -"../modules/ml/include/opencv2/ml/ml.hpp", -"../modules/imgproc/include/opencv2/imgproc/imgproc.hpp", -"../modules/calib3d/include/opencv2/calib3d/calib3d.hpp", -"../modules/features2d/include/opencv2/features2d/features2d.hpp", +"../modules/core/include/opencv2/core.hpp", +"../modules/ml/include/opencv2/ml.hpp", +"../modules/imgproc/include/opencv2/imgproc.hpp", +"../modules/calib3d/include/opencv2/calib3d.hpp", +"../modules/features2d/include/opencv2/features2d.hpp", "../modules/video/include/opencv2/video/tracking.hpp", "../modules/video/include/opencv2/video/background_segm.hpp", -"../modules/objdetect/include/opencv2/objdetect/objdetect.hpp", -"../modules/highgui/include/opencv2/highgui/highgui.hpp", +"../modules/objdetect/include/opencv2/objdetect.hpp", +"../modules/highgui/include/opencv2/highgui.hpp", ] opencv_module_list = [ diff --git a/doc/tutorials/core/interoperability_with_OpenCV_1/interoperability_with_OpenCV_1.rst b/doc/tutorials/core/interoperability_with_OpenCV_1/interoperability_with_OpenCV_1.rst index 9340a7c748..99d6692743 100644 --- a/doc/tutorials/core/interoperability_with_OpenCV_1/interoperability_with_OpenCV_1.rst +++ b/doc/tutorials/core/interoperability_with_OpenCV_1/interoperability_with_OpenCV_1.rst @@ -23,9 +23,9 @@ OpenCV 2 received reorganization. No longer are all the functions crammed into a .. code-block:: cpp - #include - #include - #include + #include + #include + #include All the OpenCV related stuff is put into the *cv* namespace to avoid name conflicts with other libraries data structures and functions. Therefore, either you need to prepend the *cv::* keyword before everything that comes from OpenCV or after the includes, you just add a directive to use this: diff --git a/doc/tutorials/features2d/feature_description/feature_description.rst b/doc/tutorials/features2d/feature_description/feature_description.rst index fe9b7cdbff..aa1a4a88be 100644 --- a/doc/tutorials/features2d/feature_description/feature_description.rst +++ b/doc/tutorials/features2d/feature_description/feature_description.rst @@ -29,10 +29,10 @@ This tutorial code's is shown lines below. You can also download it from `here < #include #include - #include "opencv2/core/core.hpp" - #include "opencv2/features2d/features2d.hpp" - #include "opencv2/highgui/highgui.hpp" - #include "opencv2/nonfree/features2d.hpp" + #include "opencv2/core.hpp" + #include "opencv2/features2d.hpp" + #include "opencv2/highgui.hpp" + #include "opencv2/nonfree.hpp" using namespace cv; diff --git a/doc/tutorials/features2d/feature_detection/feature_detection.rst b/doc/tutorials/features2d/feature_detection/feature_detection.rst index 26798f8f6f..1c9ca7cf82 100644 --- a/doc/tutorials/features2d/feature_detection/feature_detection.rst +++ b/doc/tutorials/features2d/feature_detection/feature_detection.rst @@ -28,9 +28,9 @@ This tutorial code's is shown lines below. You can also download it from `here < #include #include - #include "opencv2/core/core.hpp" - #include "opencv2/features2d/features2d.hpp" - #include "opencv2/highgui/highgui.hpp" + #include "opencv2/core.hpp" + #include "opencv2/features2d.hpp" + #include "opencv2/highgui.hpp" using namespace cv; diff --git a/doc/tutorials/features2d/feature_flann_matcher/feature_flann_matcher.rst b/doc/tutorials/features2d/feature_flann_matcher/feature_flann_matcher.rst index 47eafedbc7..9309b05c1d 100644 --- a/doc/tutorials/features2d/feature_flann_matcher/feature_flann_matcher.rst +++ b/doc/tutorials/features2d/feature_flann_matcher/feature_flann_matcher.rst @@ -25,9 +25,9 @@ This tutorial code's is shown lines below. You can also download it from `here < #include #include - #include "opencv2/core/core.hpp" - #include "opencv2/features2d/features2d.hpp" - #include "opencv2/highgui/highgui.hpp" + #include "opencv2/core.hpp" + #include "opencv2/features2d.hpp" + #include "opencv2/highgui.hpp" using namespace cv; diff --git a/doc/tutorials/features2d/feature_homography/feature_homography.rst b/doc/tutorials/features2d/feature_homography/feature_homography.rst index ad764ce9b7..0d78229599 100644 --- a/doc/tutorials/features2d/feature_homography/feature_homography.rst +++ b/doc/tutorials/features2d/feature_homography/feature_homography.rst @@ -26,10 +26,10 @@ This tutorial code's is shown lines below. You can also download it from `here < #include #include - #include "opencv2/core/core.hpp" - #include "opencv2/features2d/features2d.hpp" - #include "opencv2/highgui/highgui.hpp" - #include "opencv2/calib3d/calib3d.hpp" + #include "opencv2/core.hpp" + #include "opencv2/features2d.hpp" + #include "opencv2/highgui.hpp" + #include "opencv2/calib3d.hpp" using namespace cv; diff --git a/doc/tutorials/features2d/trackingmotion/corner_subpixeles/corner_subpixeles.rst b/doc/tutorials/features2d/trackingmotion/corner_subpixeles/corner_subpixeles.rst index afb74f2910..a267b13803 100644 --- a/doc/tutorials/features2d/trackingmotion/corner_subpixeles/corner_subpixeles.rst +++ b/doc/tutorials/features2d/trackingmotion/corner_subpixeles/corner_subpixeles.rst @@ -23,8 +23,8 @@ This tutorial code's is shown lines below. You can also download it from `here < .. code-block:: cpp - #include "opencv2/highgui/highgui.hpp" - #include "opencv2/imgproc/imgproc.hpp" + #include "opencv2/highgui.hpp" + #include "opencv2/imgproc.hpp" #include #include #include diff --git a/doc/tutorials/features2d/trackingmotion/good_features_to_track/good_features_to_track.rst b/doc/tutorials/features2d/trackingmotion/good_features_to_track/good_features_to_track.rst index e69937eaa3..9f71e987f2 100644 --- a/doc/tutorials/features2d/trackingmotion/good_features_to_track/good_features_to_track.rst +++ b/doc/tutorials/features2d/trackingmotion/good_features_to_track/good_features_to_track.rst @@ -22,8 +22,8 @@ This tutorial code's is shown lines below. You can also download it from `here < .. code-block:: cpp - #include "opencv2/highgui/highgui.hpp" - #include "opencv2/imgproc/imgproc.hpp" + #include "opencv2/highgui.hpp" + #include "opencv2/imgproc.hpp" #include #include #include diff --git a/doc/tutorials/features2d/trackingmotion/harris_detector/harris_detector.rst b/doc/tutorials/features2d/trackingmotion/harris_detector/harris_detector.rst index 05025cc835..0f6bb33fa8 100644 --- a/doc/tutorials/features2d/trackingmotion/harris_detector/harris_detector.rst +++ b/doc/tutorials/features2d/trackingmotion/harris_detector/harris_detector.rst @@ -155,8 +155,8 @@ This tutorial code's is shown lines below. You can also download it from `here < .. code-block:: cpp - #include "opencv2/highgui/highgui.hpp" - #include "opencv2/imgproc/imgproc.hpp" + #include "opencv2/highgui.hpp" + #include "opencv2/imgproc.hpp" #include #include #include diff --git a/doc/tutorials/gpu/gpu-basics-similarity/gpu-basics-similarity.rst b/doc/tutorials/gpu/gpu-basics-similarity/gpu-basics-similarity.rst index cc59084124..86400bfae4 100644 --- a/doc/tutorials/gpu/gpu-basics-similarity/gpu-basics-similarity.rst +++ b/doc/tutorials/gpu/gpu-basics-similarity/gpu-basics-similarity.rst @@ -1 +1 @@ -.. _gpuBasicsSimilarity: Similarity check (PNSR and SSIM) on the GPU ******************************************* Goal ==== In the :ref:`videoInputPSNRMSSIM` tutorial I already presented the PSNR and SSIM methods for checking the similarity between the two images. And as you could see there performing these takes quite some time, especially in the case of the SSIM. However, if the performance numbers of an OpenCV implementation for the CPU do not satisfy you and you happen to have an NVidia CUDA GPU device in your system all is not lost. You may try to port or write your algorithm for the video card. This tutorial will give a good grasp on how to approach coding by using the GPU module of OpenCV. As a prerequisite you should already know how to handle the core, highgui and imgproc modules. So, our goals are: .. container:: enumeratevisibleitemswithsquare + What's different compared to the CPU? + Create the GPU code for the PSNR and SSIM + Optimize the code for maximal performance The source code =============== You may also find the source code and these video file in the :file:`samples/cpp/tutorial_code/gpu/gpu-basics-similarity/gpu-basics-similarity` folder of the OpenCV source library or :download:`download it from here <../../../../samples/cpp/tutorial_code/gpu/gpu-basics-similarity/gpu-basics-similarity.cpp>`. The full source code is quite long (due to the controlling of the application via the command line arguments and performance measurement). Therefore, to avoid cluttering up these sections with those you'll find here only the functions itself. The PSNR returns a float number, that if the two inputs are similar between 30 and 50 (higher is better). .. literalinclude:: ../../../../samples/cpp/tutorial_code/gpu/gpu-basics-similarity/gpu-basics-similarity.cpp :language: cpp :linenos: :tab-width: 4 :lines: 165-210, 18-23, 210-235 The SSIM returns the MSSIM of the images. This is too a float number between zero and one (higher is better), however we have one for each channel. Therefore, we return a *Scalar* OpenCV data structure: .. literalinclude:: ../../../../samples/cpp/tutorial_code/gpu/gpu-basics-similarity/gpu-basics-similarity.cpp :language: cpp :linenos: :tab-width: 4 :lines: 235-355, 26-42, 357- How to do it? - The GPU ======================= Now as you can see we have three types of functions for each operation. One for the CPU and two for the GPU. The reason I made two for the GPU is too illustrate that often simple porting your CPU to GPU will actually make it slower. If you want some performance gain you will need to remember a few rules, whose I'm going to detail later on. The development of the GPU module was made so that it resembles as much as possible its CPU counterpart. This is to make porting easy. The first thing you need to do before writing any code is to link the GPU module to your project, and include the header file for the module. All the functions and data structures of the GPU are in a *gpu* sub namespace of the *cv* namespace. You may add this to the default one via the *use namespace* keyword, or mark it everywhere explicitly via the cv:: to avoid confusion. I'll do the later. .. code-block:: cpp #include // GPU structures and methods GPU stands for **g**\ raphics **p**\ rocessing **u**\ nit. It was originally build to render graphical scenes. These scenes somehow build on a lot of data. Nevertheless, these aren't all dependent one from another in a sequential way and as it is possible a parallel processing of them. Due to this a GPU will contain multiple smaller processing units. These aren't the state of the art processors and on a one on one test with a CPU it will fall behind. However, its strength lies in its numbers. In the last years there has been an increasing trend to harvest these massive parallel powers of the GPU in non-graphical scene rendering too. This gave birth to the general-purpose computation on graphics processing units (GPGPU). The GPU has its own memory. When you read data from the hard drive with OpenCV into a *Mat* object that takes place in your systems memory. The CPU works somehow directly on this (via its cache), however the GPU cannot. He has too transferred the information he will use for calculations from the system memory to its own. This is done via an upload process and takes time. In the end the result will have to be downloaded back to your system memory for your CPU to see it and use it. Porting small functions to GPU is not recommended as the upload/download time will be larger than the amount you gain by a parallel execution. *Mat* objects are stored **only** in the system memory (or the CPU cache). For getting an OpenCV matrix to the GPU you'll need to use its GPU counterpart :gpudatastructure:`GpuMat `. It works similar to the *Mat* with a 2D only limitation and no reference returning for its functions (cannot mix GPU references with CPU ones). To upload a *Mat* object to the *GPU* you need to call the *upload* function after creating an instance of the class. To download you may use simple assignment to a *Mat* object or use the *download* function. .. code-block:: cpp Mat I1; // Main memory item - read image into with imread for example gpu::GpuMat gI; // GPU matrix - for now empty gI1.upload(I1); // Upload a data from the system memory to the GPU memory I1 = gI1; // Download, gI1.download(I1) will work too Once you have your data up in the GPU memory you may call GPU enabled functions of OpenCV. Most of the functions keep the same name just as on the CPU, with the difference that they only accept *GpuMat* inputs. A full list of these you will find in the documentation: `online here `_ or the OpenCV reference manual that comes with the source code. Another thing to keep in mind is that not for all channel numbers you can make efficient algorithms on the GPU. Generally, I found that the input images for the GPU images need to be either one or four channel ones and one of the char or float type for the item sizes. No double support on the GPU, sorry. Passing other types of objects for some functions will result in an exception thrown, and an error message on the error output. The documentation details in most of the places the types accepted for the inputs. If you have three channel images as an input you can do two things: either adds a new channel (and use char elements) or split up the image and call the function for each image. The first one isn't really recommended as you waste memory. For some functions, where the position of the elements (neighbor items) doesn't matter quick solution is to just reshape it into a single channel image. This is the case for the PSNR implementation where for the *absdiff* method the value of the neighbors is not important. However, for the *GaussianBlur* this isn't an option and such need to use the split method for the SSIM. With this knowledge you can already make a GPU viable code (like mine GPU one) and run it. You'll be surprised to see that it might turn out slower than your CPU implementation. Optimization ============ The reason for this is that you're throwing out on the window the price for memory allocation and data transfer. And on the GPU this is damn high. Another possibility for optimization is to introduce asynchronous OpenCV GPU calls too with the help of the :gpudatastructure:`gpu::Stream `. 1. Memory allocation on the GPU is considerable. Therefore, if it’s possible allocate new memory as few times as possible. If you create a function what you intend to call multiple times it is a good idea to allocate any local parameters for the function only once, during the first call. To do this you create a data structure containing all the local variables you will use. For instance in case of the PSNR these are: .. code-block:: cpp struct BufferPSNR // Optimized GPU versions { // Data allocations are very expensive on GPU. Use a buffer to solve: allocate once reuse later. gpu::GpuMat gI1, gI2, gs, t1,t2; gpu::GpuMat buf; }; Then create an instance of this in the main program: .. code-block:: cpp BufferPSNR bufferPSNR; And finally pass this to the function each time you call it: .. code-block:: cpp double getPSNR_GPU_optimized(const Mat& I1, const Mat& I2, BufferPSNR& b) Now you access these local parameters as: *b.gI1*, *b.buf* and so on. The GpuMat will only reallocate itself on a new call if the new matrix size is different from the previous one. #. Avoid unnecessary function data transfers. Any small data transfer will be significant one once you go to the GPU. Therefore, if possible make all calculations in-place (in other words do not create new memory objects - for reasons explained at the previous point). For example, although expressing arithmetical operations may be easier to express in one line formulas, it will be slower. In case of the SSIM at one point I need to calculate: .. code-block:: cpp b.t1 = 2 * b.mu1_mu2 + C1; Although the upper call will succeed observe that there is a hidden data transfer present. Before it makes the addition it needs to store somewhere the multiplication. Therefore, it will create a local matrix in the background, add to that the *C1* value and finally assign that to *t1*. To avoid this we use the gpu functions, instead of the arithmetic operators: .. code-block:: cpp gpu::multiply(b.mu1_mu2, 2, b.t1); //b.t1 = 2 * b.mu1_mu2 + C1; gpu::add(b.t1, C1, b.t1); #. Use asynchronous calls (the :gpudatastructure:`gpu::Stream `). By default whenever you call a gpu function it will wait for the call to finish and return with the result afterwards. However, it is possible to make asynchronous calls, meaning it will call for the operation execution, make the costly data allocations for the algorithm and return back right away. Now you can call another function if you wish to do so. For the MSSIM this is a small optimization point. In our default implementation we split up the image into channels and call then for each channel the gpu functions. A small degree of parallelization is possible with the stream. By using a stream we can make the data allocation, upload operations while the GPU is already executing a given method. For example we need to upload two images. We queue these one after another and call already the function that processes it. The functions will wait for the upload to finish, however while that happens makes the output buffer allocations for the function to be executed next. .. code-block:: cpp gpu::Stream stream; stream.enqueueConvert(b.gI1, b.t1, CV_32F); // Upload gpu::split(b.t1, b.vI1, stream); // Methods (pass the stream as final parameter). gpu::multiply(b.vI1[i], b.vI1[i], b.I1_2, stream); // I1^2 Result and conclusion ===================== On an Intel P8700 laptop CPU paired with a low end NVidia GT220M here are the performance numbers: .. code-block:: cpp Time of PSNR CPU (averaged for 10 runs): 41.4122 milliseconds. With result of: 19.2506 Time of PSNR GPU (averaged for 10 runs): 158.977 milliseconds. With result of: 19.2506 Initial call GPU optimized: 31.3418 milliseconds. With result of: 19.2506 Time of PSNR GPU OPTIMIZED ( / 10 runs): 24.8171 milliseconds. With result of: 19.2506 Time of MSSIM CPU (averaged for 10 runs): 484.343 milliseconds. With result of B0.890964 G0.903845 R0.936934 Time of MSSIM GPU (averaged for 10 runs): 745.105 milliseconds. With result of B0.89922 G0.909051 R0.968223 Time of MSSIM GPU Initial Call 357.746 milliseconds. With result of B0.890964 G0.903845 R0.936934 Time of MSSIM GPU OPTIMIZED ( / 10 runs): 203.091 milliseconds. With result of B0.890964 G0.903845 R0.936934 In both cases we managed a performance increase of almost 100% compared to the CPU implementation. It may be just the improvement needed for your application to work. You may observe a runtime instance of this on the `YouTube here `_. .. raw:: html
\ No newline at end of file +.. _gpuBasicsSimilarity: Similarity check (PNSR and SSIM) on the GPU ******************************************* Goal ==== In the :ref:`videoInputPSNRMSSIM` tutorial I already presented the PSNR and SSIM methods for checking the similarity between the two images. And as you could see there performing these takes quite some time, especially in the case of the SSIM. However, if the performance numbers of an OpenCV implementation for the CPU do not satisfy you and you happen to have an NVidia CUDA GPU device in your system all is not lost. You may try to port or write your algorithm for the video card. This tutorial will give a good grasp on how to approach coding by using the GPU module of OpenCV. As a prerequisite you should already know how to handle the core, highgui and imgproc modules. So, our goals are: .. container:: enumeratevisibleitemswithsquare + What's different compared to the CPU? + Create the GPU code for the PSNR and SSIM + Optimize the code for maximal performance The source code =============== You may also find the source code and these video file in the :file:`samples/cpp/tutorial_code/gpu/gpu-basics-similarity/gpu-basics-similarity` folder of the OpenCV source library or :download:`download it from here <../../../../samples/cpp/tutorial_code/gpu/gpu-basics-similarity/gpu-basics-similarity.cpp>`. The full source code is quite long (due to the controlling of the application via the command line arguments and performance measurement). Therefore, to avoid cluttering up these sections with those you'll find here only the functions itself. The PSNR returns a float number, that if the two inputs are similar between 30 and 50 (higher is better). .. literalinclude:: ../../../../samples/cpp/tutorial_code/gpu/gpu-basics-similarity/gpu-basics-similarity.cpp :language: cpp :linenos: :tab-width: 4 :lines: 165-210, 18-23, 210-235 The SSIM returns the MSSIM of the images. This is too a float number between zero and one (higher is better), however we have one for each channel. Therefore, we return a *Scalar* OpenCV data structure: .. literalinclude:: ../../../../samples/cpp/tutorial_code/gpu/gpu-basics-similarity/gpu-basics-similarity.cpp :language: cpp :linenos: :tab-width: 4 :lines: 235-355, 26-42, 357- How to do it? - The GPU ======================= Now as you can see we have three types of functions for each operation. One for the CPU and two for the GPU. The reason I made two for the GPU is too illustrate that often simple porting your CPU to GPU will actually make it slower. If you want some performance gain you will need to remember a few rules, whose I'm going to detail later on. The development of the GPU module was made so that it resembles as much as possible its CPU counterpart. This is to make porting easy. The first thing you need to do before writing any code is to link the GPU module to your project, and include the header file for the module. All the functions and data structures of the GPU are in a *gpu* sub namespace of the *cv* namespace. You may add this to the default one via the *use namespace* keyword, or mark it everywhere explicitly via the cv:: to avoid confusion. I'll do the later. .. code-block:: cpp #include // GPU structures and methods GPU stands for **g**\ raphics **p**\ rocessing **u**\ nit. It was originally build to render graphical scenes. These scenes somehow build on a lot of data. Nevertheless, these aren't all dependent one from another in a sequential way and as it is possible a parallel processing of them. Due to this a GPU will contain multiple smaller processing units. These aren't the state of the art processors and on a one on one test with a CPU it will fall behind. However, its strength lies in its numbers. In the last years there has been an increasing trend to harvest these massive parallel powers of the GPU in non-graphical scene rendering too. This gave birth to the general-purpose computation on graphics processing units (GPGPU). The GPU has its own memory. When you read data from the hard drive with OpenCV into a *Mat* object that takes place in your systems memory. The CPU works somehow directly on this (via its cache), however the GPU cannot. He has too transferred the information he will use for calculations from the system memory to its own. This is done via an upload process and takes time. In the end the result will have to be downloaded back to your system memory for your CPU to see it and use it. Porting small functions to GPU is not recommended as the upload/download time will be larger than the amount you gain by a parallel execution. Mat objects are stored only in the system memory (or the CPU cache). For getting an OpenCV matrix to the GPU you'll need to use its GPU counterpart :gpudatastructure:`GpuMat `. It works similar to the Mat with a 2D only limitation and no reference returning for its functions (cannot mix GPU references with CPU ones). To upload a Mat object to the GPU you need to call the upload function after creating an instance of the class. To download you may use simple assignment to a Mat object or use the download function. .. code-block:: cpp Mat I1; // Main memory item - read image into with imread for example gpu::GpuMat gI; // GPU matrix - for now empty gI1.upload(I1); // Upload a data from the system memory to the GPU memory I1 = gI1; // Download, gI1.download(I1) will work too Once you have your data up in the GPU memory you may call GPU enabled functions of OpenCV. Most of the functions keep the same name just as on the CPU, with the difference that they only accept *GpuMat* inputs. A full list of these you will find in the documentation: `online here `_ or the OpenCV reference manual that comes with the source code. Another thing to keep in mind is that not for all channel numbers you can make efficient algorithms on the GPU. Generally, I found that the input images for the GPU images need to be either one or four channel ones and one of the char or float type for the item sizes. No double support on the GPU, sorry. Passing other types of objects for some functions will result in an exception thrown, and an error message on the error output. The documentation details in most of the places the types accepted for the inputs. If you have three channel images as an input you can do two things: either adds a new channel (and use char elements) or split up the image and call the function for each image. The first one isn't really recommended as you waste memory. For some functions, where the position of the elements (neighbor items) doesn't matter quick solution is to just reshape it into a single channel image. This is the case for the PSNR implementation where for the *absdiff* method the value of the neighbors is not important. However, for the *GaussianBlur* this isn't an option and such need to use the split method for the SSIM. With this knowledge you can already make a GPU viable code (like mine GPU one) and run it. You'll be surprised to see that it might turn out slower than your CPU implementation. Optimization ============ The reason for this is that you're throwing out on the window the price for memory allocation and data transfer. And on the GPU this is damn high. Another possibility for optimization is to introduce asynchronous OpenCV GPU calls too with the help of the :gpudatastructure:`gpu::Stream`. 1. Memory allocation on the GPU is considerable. Therefore, if it’s possible allocate new memory as few times as possible. If you create a function what you intend to call multiple times it is a good idea to allocate any local parameters for the function only once, during the first call. To do this you create a data structure containing all the local variables you will use. For instance in case of the PSNR these are: .. code-block:: cpp struct BufferPSNR // Optimized GPU versions { // Data allocations are very expensive on GPU. Use a buffer to solve: allocate once reuse later. gpu::GpuMat gI1, gI2, gs, t1,t2; gpu::GpuMat buf; }; Then create an instance of this in the main program: .. code-block:: cpp BufferPSNR bufferPSNR; And finally pass this to the function each time you call it: .. code-block:: cpp double getPSNR_GPU_optimized(const Mat& I1, const Mat& I2, BufferPSNR& b) Now you access these local parameters as: *b.gI1*, *b.buf* and so on. The GpuMat will only reallocate itself on a new call if the new matrix size is different from the previous one. #. Avoid unnecessary function data transfers. Any small data transfer will be significant one once you go to the GPU. Therefore, if possible make all calculations in-place (in other words do not create new memory objects - for reasons explained at the previous point). For example, although expressing arithmetical operations may be easier to express in one line formulas, it will be slower. In case of the SSIM at one point I need to calculate: .. code-block:: cpp b.t1 = 2 * b.mu1_mu2 + C1; Although the upper call will succeed observe that there is a hidden data transfer present. Before it makes the addition it needs to store somewhere the multiplication. Therefore, it will create a local matrix in the background, add to that the *C1* value and finally assign that to *t1*. To avoid this we use the gpu functions, instead of the arithmetic operators: .. code-block:: cpp gpu::multiply(b.mu1_mu2, 2, b.t1); //b.t1 = 2 * b.mu1_mu2 + C1; gpu::add(b.t1, C1, b.t1); #. Use asynchronous calls (the :gpudatastructure:`gpu::Stream `). By default whenever you call a gpu function it will wait for the call to finish and return with the result afterwards. However, it is possible to make asynchronous calls, meaning it will call for the operation execution, make the costly data allocations for the algorithm and return back right away. Now you can call another function if you wish to do so. For the MSSIM this is a small optimization point. In our default implementation we split up the image into channels and call then for each channel the gpu functions. A small degree of parallelization is possible with the stream. By using a stream we can make the data allocation, upload operations while the GPU is already executing a given method. For example we need to upload two images. We queue these one after another and call already the function that processes it. The functions will wait for the upload to finish, however while that happens makes the output buffer allocations for the function to be executed next. .. code-block:: cpp gpu::Stream stream; stream.enqueueConvert(b.gI1, b.t1, CV_32F); // Upload gpu::split(b.t1, b.vI1, stream); // Methods (pass the stream as final parameter). gpu::multiply(b.vI1[i], b.vI1[i], b.I1_2, stream); // I1^2 Result and conclusion ===================== On an Intel P8700 laptop CPU paired with a low end NVidia GT220M here are the performance numbers: .. code-block:: cpp Time of PSNR CPU (averaged for 10 runs): 41.4122 milliseconds. With result of: 19.2506 Time of PSNR GPU (averaged for 10 runs): 158.977 milliseconds. With result of: 19.2506 Initial call GPU optimized: 31.3418 milliseconds. With result of: 19.2506 Time of PSNR GPU OPTIMIZED ( / 10 runs): 24.8171 milliseconds. With result of: 19.2506 Time of MSSIM CPU (averaged for 10 runs): 484.343 milliseconds. With result of B0.890964 G0.903845 R0.936934 Time of MSSIM GPU (averaged for 10 runs): 745.105 milliseconds. With result of B0.89922 G0.909051 R0.968223 Time of MSSIM GPU Initial Call 357.746 milliseconds. With result of B0.890964 G0.903845 R0.936934 Time of MSSIM GPU OPTIMIZED ( / 10 runs): 203.091 milliseconds. With result of B0.890964 G0.903845 R0.936934 In both cases we managed a performance increase of almost 100% compared to the CPU implementation. It may be just the improvement needed for your application to work. You may observe a runtime instance of this on the `YouTube here `_. .. raw:: html
\ No newline at end of file diff --git a/doc/tutorials/imgproc/erosion_dilatation/erosion_dilatation.rst b/doc/tutorials/imgproc/erosion_dilatation/erosion_dilatation.rst index ff5a4d9d9d..e163348f03 100644 --- a/doc/tutorials/imgproc/erosion_dilatation/erosion_dilatation.rst +++ b/doc/tutorials/imgproc/erosion_dilatation/erosion_dilatation.rst @@ -74,8 +74,8 @@ This tutorial code's is shown lines below. You can also download it from `here < .. code-block:: cpp - #include "opencv2/imgproc/imgproc.hpp" - #include "opencv2/highgui/highgui.hpp" + #include "opencv2/imgproc.hpp" + #include "opencv2/highgui.hpp" #include "highgui.h" #include #include diff --git a/doc/tutorials/imgproc/gausian_median_blur_bilateral_filter/gausian_median_blur_bilateral_filter.rst b/doc/tutorials/imgproc/gausian_median_blur_bilateral_filter/gausian_median_blur_bilateral_filter.rst index 0e82e50a42..b470d51ea3 100644 --- a/doc/tutorials/imgproc/gausian_median_blur_bilateral_filter/gausian_median_blur_bilateral_filter.rst +++ b/doc/tutorials/imgproc/gausian_median_blur_bilateral_filter/gausian_median_blur_bilateral_filter.rst @@ -122,8 +122,8 @@ Code .. code-block:: cpp - #include "opencv2/imgproc/imgproc.hpp" - #include "opencv2/highgui/highgui.hpp" + #include "opencv2/imgproc.hpp" + #include "opencv2/highgui.hpp" using namespace std; using namespace cv; diff --git a/doc/tutorials/imgproc/histograms/back_projection/back_projection.rst b/doc/tutorials/imgproc/histograms/back_projection/back_projection.rst index 9231372632..c456c9e936 100644 --- a/doc/tutorials/imgproc/histograms/back_projection/back_projection.rst +++ b/doc/tutorials/imgproc/histograms/back_projection/back_projection.rst @@ -107,8 +107,8 @@ Code .. code-block:: cpp - #include "opencv2/imgproc/imgproc.hpp" - #include "opencv2/highgui/highgui.hpp" + #include "opencv2/imgproc.hpp" + #include "opencv2/highgui.hpp" #include diff --git a/doc/tutorials/imgproc/histograms/histogram_calculation/histogram_calculation.rst b/doc/tutorials/imgproc/histograms/histogram_calculation/histogram_calculation.rst index de1567abb2..133a613add 100644 --- a/doc/tutorials/imgproc/histograms/histogram_calculation/histogram_calculation.rst +++ b/doc/tutorials/imgproc/histograms/histogram_calculation/histogram_calculation.rst @@ -88,8 +88,8 @@ Code .. code-block:: cpp - #include "opencv2/highgui/highgui.hpp" - #include "opencv2/imgproc/imgproc.hpp" + #include "opencv2/highgui.hpp" + #include "opencv2/imgproc.hpp" #include #include diff --git a/doc/tutorials/imgproc/histograms/histogram_comparison/histogram_comparison.rst b/doc/tutorials/imgproc/histograms/histogram_comparison/histogram_comparison.rst index be9dc7f81b..1b1df197d7 100644 --- a/doc/tutorials/imgproc/histograms/histogram_comparison/histogram_comparison.rst +++ b/doc/tutorials/imgproc/histograms/histogram_comparison/histogram_comparison.rst @@ -86,8 +86,8 @@ Code .. code-block:: cpp - #include "opencv2/highgui/highgui.hpp" - #include "opencv2/imgproc/imgproc.hpp" + #include "opencv2/highgui.hpp" + #include "opencv2/imgproc.hpp" #include #include diff --git a/doc/tutorials/imgproc/histograms/histogram_equalization/histogram_equalization.rst b/doc/tutorials/imgproc/histograms/histogram_equalization/histogram_equalization.rst index 24534a7068..8f0c96f5e5 100644 --- a/doc/tutorials/imgproc/histograms/histogram_equalization/histogram_equalization.rst +++ b/doc/tutorials/imgproc/histograms/histogram_equalization/histogram_equalization.rst @@ -89,8 +89,8 @@ Code .. code-block:: cpp - #include "opencv2/highgui/highgui.hpp" - #include "opencv2/imgproc/imgproc.hpp" + #include "opencv2/highgui.hpp" + #include "opencv2/imgproc.hpp" #include #include diff --git a/doc/tutorials/imgproc/histograms/template_matching/template_matching.rst b/doc/tutorials/imgproc/histograms/template_matching/template_matching.rst index e0c643d05c..d8a91560e9 100644 --- a/doc/tutorials/imgproc/histograms/template_matching/template_matching.rst +++ b/doc/tutorials/imgproc/histograms/template_matching/template_matching.rst @@ -131,8 +131,8 @@ Code .. code-block:: cpp - #include "opencv2/highgui/highgui.hpp" - #include "opencv2/imgproc/imgproc.hpp" + #include "opencv2/highgui.hpp" + #include "opencv2/imgproc.hpp" #include #include diff --git a/doc/tutorials/imgproc/imgtrans/canny_detector/canny_detector.rst b/doc/tutorials/imgproc/imgtrans/canny_detector/canny_detector.rst index 52b10468ba..01c9050f26 100644 --- a/doc/tutorials/imgproc/imgtrans/canny_detector/canny_detector.rst +++ b/doc/tutorials/imgproc/imgtrans/canny_detector/canny_detector.rst @@ -90,8 +90,8 @@ Code .. code-block:: cpp - #include "opencv2/imgproc/imgproc.hpp" - #include "opencv2/highgui/highgui.hpp" + #include "opencv2/imgproc.hpp" + #include "opencv2/highgui.hpp" #include #include diff --git a/doc/tutorials/imgproc/imgtrans/copyMakeBorder/copyMakeBorder.rst b/doc/tutorials/imgproc/imgtrans/copyMakeBorder/copyMakeBorder.rst index 337ecd7ebd..1f72f13662 100644 --- a/doc/tutorials/imgproc/imgtrans/copyMakeBorder/copyMakeBorder.rst +++ b/doc/tutorials/imgproc/imgtrans/copyMakeBorder/copyMakeBorder.rst @@ -52,8 +52,8 @@ Code .. code-block:: cpp - #include "opencv2/imgproc/imgproc.hpp" - #include "opencv2/highgui/highgui.hpp" + #include "opencv2/imgproc.hpp" + #include "opencv2/highgui.hpp" #include #include diff --git a/doc/tutorials/imgproc/imgtrans/filter_2d/filter_2d.rst b/doc/tutorials/imgproc/imgtrans/filter_2d/filter_2d.rst index 1c81ba33ae..5ea70cc395 100644 --- a/doc/tutorials/imgproc/imgtrans/filter_2d/filter_2d.rst +++ b/doc/tutorials/imgproc/imgtrans/filter_2d/filter_2d.rst @@ -77,8 +77,8 @@ Code .. code-block:: cpp - #include "opencv2/imgproc/imgproc.hpp" - #include "opencv2/highgui/highgui.hpp" + #include "opencv2/imgproc.hpp" + #include "opencv2/highgui.hpp" #include #include diff --git a/doc/tutorials/imgproc/imgtrans/hough_circle/hough_circle.rst b/doc/tutorials/imgproc/imgtrans/hough_circle/hough_circle.rst index 6d307beec5..ecd4ba2192 100644 --- a/doc/tutorials/imgproc/imgtrans/hough_circle/hough_circle.rst +++ b/doc/tutorials/imgproc/imgtrans/hough_circle/hough_circle.rst @@ -48,8 +48,8 @@ Code .. code-block:: cpp - #include "opencv2/highgui/highgui.hpp" - #include "opencv2/imgproc/imgproc.hpp" + #include "opencv2/highgui.hpp" + #include "opencv2/imgproc.hpp" #include #include diff --git a/doc/tutorials/imgproc/imgtrans/hough_lines/hough_lines.rst b/doc/tutorials/imgproc/imgtrans/hough_lines/hough_lines.rst index dfb57c03c7..6b872bff51 100644 --- a/doc/tutorials/imgproc/imgtrans/hough_lines/hough_lines.rst +++ b/doc/tutorials/imgproc/imgtrans/hough_lines/hough_lines.rst @@ -104,8 +104,8 @@ Code .. code-block:: cpp - #include "opencv2/highgui/highgui.hpp" - #include "opencv2/imgproc/imgproc.hpp" + #include "opencv2/highgui.hpp" + #include "opencv2/imgproc.hpp" #include diff --git a/doc/tutorials/imgproc/imgtrans/laplace_operator/laplace_operator.rst b/doc/tutorials/imgproc/imgtrans/laplace_operator/laplace_operator.rst index da9373201e..5f2d0d0b11 100644 --- a/doc/tutorials/imgproc/imgtrans/laplace_operator/laplace_operator.rst +++ b/doc/tutorials/imgproc/imgtrans/laplace_operator/laplace_operator.rst @@ -59,8 +59,8 @@ Code .. code-block:: cpp - #include "opencv2/imgproc/imgproc.hpp" - #include "opencv2/highgui/highgui.hpp" + #include "opencv2/imgproc.hpp" + #include "opencv2/highgui.hpp" #include #include diff --git a/doc/tutorials/imgproc/imgtrans/remap/remap.rst b/doc/tutorials/imgproc/imgtrans/remap/remap.rst index 1aa3b3841f..a8b9fdf744 100644 --- a/doc/tutorials/imgproc/imgtrans/remap/remap.rst +++ b/doc/tutorials/imgproc/imgtrans/remap/remap.rst @@ -63,8 +63,8 @@ Code .. code-block:: cpp - #include "opencv2/highgui/highgui.hpp" - #include "opencv2/imgproc/imgproc.hpp" + #include "opencv2/highgui.hpp" + #include "opencv2/imgproc.hpp" #include #include diff --git a/doc/tutorials/imgproc/imgtrans/sobel_derivatives/sobel_derivatives.rst b/doc/tutorials/imgproc/imgtrans/sobel_derivatives/sobel_derivatives.rst index 625ca160dd..fe25937975 100644 --- a/doc/tutorials/imgproc/imgtrans/sobel_derivatives/sobel_derivatives.rst +++ b/doc/tutorials/imgproc/imgtrans/sobel_derivatives/sobel_derivatives.rst @@ -125,8 +125,8 @@ Code .. code-block:: cpp - #include "opencv2/imgproc/imgproc.hpp" - #include "opencv2/highgui/highgui.hpp" + #include "opencv2/imgproc.hpp" + #include "opencv2/highgui.hpp" #include #include diff --git a/doc/tutorials/imgproc/imgtrans/warp_affine/warp_affine.rst b/doc/tutorials/imgproc/imgtrans/warp_affine/warp_affine.rst index 8c08d22e42..b601929781 100644 --- a/doc/tutorials/imgproc/imgtrans/warp_affine/warp_affine.rst +++ b/doc/tutorials/imgproc/imgtrans/warp_affine/warp_affine.rst @@ -97,8 +97,8 @@ Code .. code-block:: cpp - #include "opencv2/highgui/highgui.hpp" - #include "opencv2/imgproc/imgproc.hpp" + #include "opencv2/highgui.hpp" + #include "opencv2/imgproc.hpp" #include #include diff --git a/doc/tutorials/imgproc/opening_closing_hats/opening_closing_hats.rst b/doc/tutorials/imgproc/opening_closing_hats/opening_closing_hats.rst index 4fe632368a..6baa3a3d71 100644 --- a/doc/tutorials/imgproc/opening_closing_hats/opening_closing_hats.rst +++ b/doc/tutorials/imgproc/opening_closing_hats/opening_closing_hats.rst @@ -115,8 +115,8 @@ This tutorial code's is shown lines below. You can also download it from `here < .. code-block:: cpp - #include "opencv2/imgproc/imgproc.hpp" - #include "opencv2/highgui/highgui.hpp" + #include "opencv2/imgproc.hpp" + #include "opencv2/highgui.hpp" #include #include diff --git a/doc/tutorials/imgproc/pyramids/pyramids.rst b/doc/tutorials/imgproc/pyramids/pyramids.rst index 8b8d11a741..00baae2ac1 100644 --- a/doc/tutorials/imgproc/pyramids/pyramids.rst +++ b/doc/tutorials/imgproc/pyramids/pyramids.rst @@ -84,8 +84,8 @@ This tutorial code's is shown lines below. You can also download it from `here < .. code-block:: cpp - #include "opencv2/imgproc/imgproc.hpp" - #include "opencv2/highgui/highgui.hpp" + #include "opencv2/imgproc.hpp" + #include "opencv2/highgui.hpp" #include #include #include diff --git a/doc/tutorials/imgproc/shapedescriptors/bounding_rects_circles/bounding_rects_circles.rst b/doc/tutorials/imgproc/shapedescriptors/bounding_rects_circles/bounding_rects_circles.rst index d073a1b925..f91730ec88 100644 --- a/doc/tutorials/imgproc/shapedescriptors/bounding_rects_circles/bounding_rects_circles.rst +++ b/doc/tutorials/imgproc/shapedescriptors/bounding_rects_circles/bounding_rects_circles.rst @@ -25,8 +25,8 @@ This tutorial code's is shown lines below. You can also download it from `here < .. code-block:: cpp - #include "opencv2/highgui/highgui.hpp" - #include "opencv2/imgproc/imgproc.hpp" + #include "opencv2/highgui.hpp" + #include "opencv2/imgproc.hpp" #include #include #include diff --git a/doc/tutorials/imgproc/shapedescriptors/bounding_rotated_ellipses/bounding_rotated_ellipses.rst b/doc/tutorials/imgproc/shapedescriptors/bounding_rotated_ellipses/bounding_rotated_ellipses.rst index 894df8605e..0986e1edcd 100644 --- a/doc/tutorials/imgproc/shapedescriptors/bounding_rotated_ellipses/bounding_rotated_ellipses.rst +++ b/doc/tutorials/imgproc/shapedescriptors/bounding_rotated_ellipses/bounding_rotated_ellipses.rst @@ -25,8 +25,8 @@ This tutorial code's is shown lines below. You can also download it from `here < .. code-block:: cpp - #include "opencv2/highgui/highgui.hpp" - #include "opencv2/imgproc/imgproc.hpp" + #include "opencv2/highgui.hpp" + #include "opencv2/imgproc.hpp" #include #include #include diff --git a/doc/tutorials/imgproc/shapedescriptors/find_contours/find_contours.rst b/doc/tutorials/imgproc/shapedescriptors/find_contours/find_contours.rst index decdf31ef6..1fca7df93a 100644 --- a/doc/tutorials/imgproc/shapedescriptors/find_contours/find_contours.rst +++ b/doc/tutorials/imgproc/shapedescriptors/find_contours/find_contours.rst @@ -23,8 +23,8 @@ This tutorial code's is shown lines below. You can also download it from `here < .. code-block:: cpp - #include "opencv2/highgui/highgui.hpp" - #include "opencv2/imgproc/imgproc.hpp" + #include "opencv2/highgui.hpp" + #include "opencv2/imgproc.hpp" #include #include #include diff --git a/doc/tutorials/imgproc/shapedescriptors/hull/hull.rst b/doc/tutorials/imgproc/shapedescriptors/hull/hull.rst index c6abdd2c82..c1ed79cea1 100644 --- a/doc/tutorials/imgproc/shapedescriptors/hull/hull.rst +++ b/doc/tutorials/imgproc/shapedescriptors/hull/hull.rst @@ -23,8 +23,8 @@ This tutorial code's is shown lines below. You can also download it from `here < .. code-block:: cpp - #include "opencv2/highgui/highgui.hpp" - #include "opencv2/imgproc/imgproc.hpp" + #include "opencv2/highgui.hpp" + #include "opencv2/imgproc.hpp" #include #include #include diff --git a/doc/tutorials/imgproc/shapedescriptors/moments/moments.rst b/doc/tutorials/imgproc/shapedescriptors/moments/moments.rst index 6ef2de6ee6..15ac2f51f7 100644 --- a/doc/tutorials/imgproc/shapedescriptors/moments/moments.rst +++ b/doc/tutorials/imgproc/shapedescriptors/moments/moments.rst @@ -25,8 +25,8 @@ This tutorial code's is shown lines below. You can also download it from `here < .. code-block:: cpp - #include "opencv2/highgui/highgui.hpp" - #include "opencv2/imgproc/imgproc.hpp" + #include "opencv2/highgui.hpp" + #include "opencv2/imgproc.hpp" #include #include #include diff --git a/doc/tutorials/imgproc/shapedescriptors/point_polygon_test/point_polygon_test.rst b/doc/tutorials/imgproc/shapedescriptors/point_polygon_test/point_polygon_test.rst index a73a8e92e5..b7f72c8150 100644 --- a/doc/tutorials/imgproc/shapedescriptors/point_polygon_test/point_polygon_test.rst +++ b/doc/tutorials/imgproc/shapedescriptors/point_polygon_test/point_polygon_test.rst @@ -23,8 +23,8 @@ This tutorial code's is shown lines below. You can also download it from `here < .. code-block:: cpp - #include "opencv2/highgui/highgui.hpp" - #include "opencv2/imgproc/imgproc.hpp" + #include "opencv2/highgui.hpp" + #include "opencv2/imgproc.hpp" #include #include #include diff --git a/doc/tutorials/imgproc/threshold/threshold.rst b/doc/tutorials/imgproc/threshold/threshold.rst index d76c057e54..c4e8ddf647 100644 --- a/doc/tutorials/imgproc/threshold/threshold.rst +++ b/doc/tutorials/imgproc/threshold/threshold.rst @@ -134,8 +134,8 @@ The tutorial code's is shown lines below. You can also download it from `here #include diff --git a/doc/tutorials/objdetect/cascade_classifier/cascade_classifier.rst b/doc/tutorials/objdetect/cascade_classifier/cascade_classifier.rst index cabb81c010..146a0ec0be 100644 --- a/doc/tutorials/objdetect/cascade_classifier/cascade_classifier.rst +++ b/doc/tutorials/objdetect/cascade_classifier/cascade_classifier.rst @@ -26,9 +26,9 @@ This tutorial code's is shown lines below. You can also download it from `here < .. code-block:: cpp - #include "opencv2/objdetect/objdetect.hpp" - #include "opencv2/highgui/highgui.hpp" - #include "opencv2/imgproc/imgproc.hpp" + #include "opencv2/objdetect.hpp" + #include "opencv2/highgui.hpp" + #include "opencv2/imgproc.hpp" #include #include diff --git a/include/opencv/cv.h b/include/opencv/cv.h index f9831cf5cd..c878e68818 100644 --- a/include/opencv/cv.h +++ b/include/opencv/cv.h @@ -61,14 +61,14 @@ //CV_WARNING("This is a deprecated opencv header provided for compatibility. Please include a header from a corresponding opencv module") #include "opencv2/core/core_c.h" -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" #include "opencv2/imgproc/imgproc_c.h" -#include "opencv2/imgproc/imgproc.hpp" -#include "opencv2/video/tracking.hpp" -#include "opencv2/features2d/features2d.hpp" -#include "opencv2/flann/flann.hpp" -#include "opencv2/calib3d/calib3d.hpp" -#include "opencv2/objdetect/objdetect.hpp" +#include "opencv2/imgproc.hpp" +#include "opencv2/video.hpp" +#include "opencv2/features2d.hpp" +#include "opencv2/flann.hpp" +#include "opencv2/calib3d.hpp" +#include "opencv2/objdetect.hpp" #include "opencv2/legacy/compat.hpp" #if !defined(CV_IMPL) diff --git a/include/opencv/cvaux.h b/include/opencv/cvaux.h index b15d068666..52d4f0b648 100644 --- a/include/opencv/cvaux.h +++ b/include/opencv/cvaux.h @@ -47,18 +47,17 @@ //#endif #include "opencv2/core/core_c.h" -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" #include "opencv2/imgproc/imgproc_c.h" -#include "opencv2/imgproc/imgproc.hpp" -#include "opencv2/video/tracking.hpp" -#include "opencv2/video/background_segm.hpp" -#include "opencv2/features2d/features2d.hpp" -#include "opencv2/calib3d/calib3d.hpp" -#include "opencv2/objdetect/objdetect.hpp" -#include "opencv2/legacy/legacy.hpp" +#include "opencv2/imgproc.hpp" +#include "opencv2/video.hpp" +#include "opencv2/features2d.hpp" +#include "opencv2/calib3d.hpp" +#include "opencv2/objdetect.hpp" +#include "opencv2/legacy.hpp" #include "opencv2/legacy/compat.hpp" #include "opencv2/legacy/blobtrack.hpp" -#include "opencv2/contrib/contrib.hpp" +#include "opencv2/contrib.hpp" #endif diff --git a/include/opencv/cxcore.h b/include/opencv/cxcore.h index d52ad4fb9b..9be80ae96f 100644 --- a/include/opencv/cxcore.h +++ b/include/opencv/cxcore.h @@ -48,6 +48,6 @@ //#endif #include "opencv2/core/core_c.h" -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" #endif diff --git a/include/opencv/highgui.h b/include/opencv/highgui.h index 9725c9f751..56874e7383 100644 --- a/include/opencv/highgui.h +++ b/include/opencv/highgui.h @@ -43,8 +43,8 @@ #define __OPENCV_OLD_HIGHGUI_H__ #include "opencv2/core/core_c.h" -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" #include "opencv2/highgui/highgui_c.h" -#include "opencv2/highgui/highgui.hpp" +#include "opencv2/highgui.hpp" #endif diff --git a/include/opencv/ml.h b/include/opencv/ml.h index 0383a2f19c..ac21f3c219 100644 --- a/include/opencv/ml.h +++ b/include/opencv/ml.h @@ -42,7 +42,7 @@ #define __OPENCV_OLD_ML_H__ #include "opencv2/core/core_c.h" -#include "opencv2/core/core.hpp" -#include "opencv2/ml/ml.hpp" +#include "opencv2/core.hpp" +#include "opencv2/ml.hpp" #endif diff --git a/include/opencv2/opencv.hpp b/include/opencv2/opencv.hpp index f89547c9be..f9c15df3d4 100644 --- a/include/opencv2/opencv.hpp +++ b/include/opencv2/opencv.hpp @@ -44,18 +44,18 @@ #define __OPENCV_ALL_HPP__ #include "opencv2/core/core_c.h" -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" #include "opencv2/flann/miniflann.hpp" #include "opencv2/imgproc/imgproc_c.h" -#include "opencv2/imgproc/imgproc.hpp" -#include "opencv2/photo/photo.hpp" -#include "opencv2/video/video.hpp" -#include "opencv2/features2d/features2d.hpp" -#include "opencv2/objdetect/objdetect.hpp" -#include "opencv2/calib3d/calib3d.hpp" -#include "opencv2/ml/ml.hpp" +#include "opencv2/imgproc.hpp" +#include "opencv2/photo.hpp" +#include "opencv2/video.hpp" +#include "opencv2/features2d.hpp" +#include "opencv2/objdetect.hpp" +#include "opencv2/calib3d.hpp" +#include "opencv2/ml.hpp" #include "opencv2/highgui/highgui_c.h" -#include "opencv2/highgui/highgui.hpp" -#include "opencv2/contrib/contrib.hpp" +#include "opencv2/highgui.hpp" +#include "opencv2/contrib.hpp" #endif diff --git a/modules/CMakeLists.txt b/modules/CMakeLists.txt index 4a6ed6d11e..9d41ebe180 100644 --- a/modules/CMakeLists.txt +++ b/modules/CMakeLists.txt @@ -1,3 +1,5 @@ +add_definition(-D__OPENCV_BUILD=1) + if(NOT OPENCV_MODULES_PATH) set(OPENCV_MODULES_PATH "${CMAKE_CURRENT_SOURCE_DIR}") endif() diff --git a/modules/androidcamera/include/camera_activity.hpp b/modules/androidcamera/include/camera_activity.hpp index 76a63b06ec..8aa25b620e 100644 --- a/modules/androidcamera/include/camera_activity.hpp +++ b/modules/androidcamera/include/camera_activity.hpp @@ -2,7 +2,6 @@ #define _CAMERAACTIVITY_H_ #include -//#include class CameraActivity { diff --git a/modules/calib3d/include/opencv2/calib3d/calib3d.hpp b/modules/calib3d/include/opencv2/calib3d.hpp similarity index 98% rename from modules/calib3d/include/opencv2/calib3d/calib3d.hpp rename to modules/calib3d/include/opencv2/calib3d.hpp index 701f1ecb04..61c2d2a2df 100644 --- a/modules/calib3d/include/opencv2/calib3d/calib3d.hpp +++ b/modules/calib3d/include/opencv2/calib3d.hpp @@ -43,8 +43,8 @@ #ifndef __OPENCV_CALIB3D_HPP__ #define __OPENCV_CALIB3D_HPP__ -#include "opencv2/core/core.hpp" -#include "opencv2/features2d/features2d.hpp" +#include "opencv2/core.hpp" +#include "opencv2/features2d.hpp" #ifdef __cplusplus extern "C" { @@ -644,18 +644,18 @@ CV_EXPORTS Mat findFundamentalMat( InputArray points1, InputArray points2, double param1=3., double param2=0.99); //! finds essential matrix from a set of corresponding 2D points using five-point algorithm -CV_EXPORTS Mat findEssentialMat( InputArray points1, InputArray points2, double focal = 1.0, Point2d pp = Point2d(0, 0), - int method = CV_RANSAC, - double prob = 0.999, double threshold = 1.0, OutputArray mask = noArray() ); +CV_EXPORTS Mat findEssentialMat( InputArray points1, InputArray points2, double focal = 1.0, Point2d pp = Point2d(0, 0), + int method = CV_RANSAC, + double prob = 0.999, double threshold = 1.0, OutputArray mask = noArray() ); //! decompose essential matrix to possible rotation matrix and one translation vector -CV_EXPORTS void decomposeEssentialMat( InputArray E, OutputArray R1, OutputArray R2, OutputArray t ); +CV_EXPORTS void decomposeEssentialMat( InputArray E, OutputArray R1, OutputArray R2, OutputArray t ); //! recover relative camera pose from a set of corresponding 2D points -CV_EXPORTS int recoverPose( InputArray E, InputArray points1, InputArray points2, OutputArray R, OutputArray t, - double focal = 1.0, Point2d pp = Point2d(0, 0), - InputOutputArray mask = noArray()); - +CV_EXPORTS int recoverPose( InputArray E, InputArray points1, InputArray points2, OutputArray R, OutputArray t, + double focal = 1.0, Point2d pp = Point2d(0, 0), + InputOutputArray mask = noArray()); + //! finds coordinates of epipolar lines corresponding the specified points CV_EXPORTS void computeCorrespondEpilines( InputArray points, @@ -680,7 +680,7 @@ public: enum { STEREO_DISP_SCALE=16, STEREO_PREFILTER_NORMALIZED_RESPONSE = 0, STEREO_PREFILTER_XSOBEL = 1 }; CV_EXPORTS Ptr createStereoBM(int numDisparities=0, int SADWindowSize=21); - + CV_EXPORTS Ptr createStereoSGBM(int minDisparity, int numDisparities, int SADWindowSize, int P1=0, int P2=0, int disp12MaxDiff=0, int preFilterCap=0, int uniquenessRatio=0, diff --git a/modules/calib3d/perf/perf_precomp.hpp b/modules/calib3d/perf/perf_precomp.hpp index 6cee5b90e6..86312de1b8 100644 --- a/modules/calib3d/perf/perf_precomp.hpp +++ b/modules/calib3d/perf/perf_precomp.hpp @@ -9,10 +9,10 @@ #ifndef __OPENCV_PERF_PRECOMP_HPP__ #define __OPENCV_PERF_PRECOMP_HPP__ -#include "opencv2/ts/ts.hpp" -#include "opencv2/calib3d/calib3d.hpp" -#include "opencv2/highgui/highgui.hpp" -#include "opencv2/imgproc/imgproc.hpp" +#include "opencv2/ts.hpp" +#include "opencv2/calib3d.hpp" +#include "opencv2/highgui.hpp" +#include "opencv2/imgproc.hpp" #ifdef GTEST_CREATE_SHARED_LIBRARY #error no modules except ts should have GTEST_CREATE_SHARED_LIBRARY defined diff --git a/modules/calib3d/src/calibinit.cpp b/modules/calib3d/src/calibinit.cpp index 44ef0fa617..0a349584e7 100644 --- a/modules/calib3d/src/calibinit.cpp +++ b/modules/calib3d/src/calibinit.cpp @@ -69,7 +69,7 @@ #ifdef DEBUG_CHESSBOARD # include "opencv2/opencv_modules.hpp" # ifdef HAVE_OPENCV_HIGHGUI -# include "opencv2/highgui/highgui.hpp" +# include "opencv2/highgui.hpp" # else # undef DEBUG_CHESSBOARD # endif diff --git a/modules/calib3d/src/checkchessboard.cpp b/modules/calib3d/src/checkchessboard.cpp index 60e275d40a..9191fc8c84 100644 --- a/modules/calib3d/src/checkchessboard.cpp +++ b/modules/calib3d/src/checkchessboard.cpp @@ -49,7 +49,7 @@ #if defined(DEBUG_WINDOWS) # include "opencv2/opencv_modules.hpp" # ifdef HAVE_OPENCV_HIGHGUI -# include "opencv2/highgui/highgui.hpp" +# include "opencv2/highgui.hpp" # else # undef DEBUG_WINDOWS # endif diff --git a/modules/calib3d/src/circlesgrid.cpp b/modules/calib3d/src/circlesgrid.cpp index 5cf77a939d..9d893ffe97 100644 --- a/modules/calib3d/src/circlesgrid.cpp +++ b/modules/calib3d/src/circlesgrid.cpp @@ -46,7 +46,7 @@ #ifdef DEBUG_CIRCLES # include "opencv2/opencv_modules.hpp" # ifdef HAVE_OPENCV_HIGHGUI -# include "opencv2/highgui/highgui.hpp" +# include "opencv2/highgui.hpp" # else # undef DEBUG_CIRCLES # endif diff --git a/modules/calib3d/src/precomp.hpp b/modules/calib3d/src/precomp.hpp index b1b92d261d..5951ea1fd2 100644 --- a/modules/calib3d/src/precomp.hpp +++ b/modules/calib3d/src/precomp.hpp @@ -46,11 +46,11 @@ #include "cvconfig.h" #endif -#include "opencv2/calib3d/calib3d.hpp" -#include "opencv2/imgproc/imgproc.hpp" +#include "opencv2/calib3d.hpp" +#include "opencv2/imgproc.hpp" #include "opencv2/imgproc/imgproc_c.h" #include "opencv2/core/internal.hpp" -#include "opencv2/features2d/features2d.hpp" +#include "opencv2/features2d.hpp" #include #ifdef HAVE_TEGRA_OPTIMIZATION diff --git a/modules/calib3d/test/test_chessboardgenerator.hpp b/modules/calib3d/test/test_chessboardgenerator.hpp index dbd9213256..97d0fedf5f 100644 --- a/modules/calib3d/test/test_chessboardgenerator.hpp +++ b/modules/calib3d/test/test_chessboardgenerator.hpp @@ -1,7 +1,7 @@ #ifndef CV_CHESSBOARDGENERATOR_H143KJTVYM389YTNHKFDHJ89NYVMO3VLMEJNTBGUEIYVCM203P #define CV_CHESSBOARDGENERATOR_H143KJTVYM389YTNHKFDHJ89NYVMO3VLMEJNTBGUEIYVCM203P -#include "opencv2/calib3d/calib3d.hpp" +#include "opencv2/calib3d.hpp" namespace cv { diff --git a/modules/calib3d/test/test_precomp.hpp b/modules/calib3d/test/test_precomp.hpp index e0fcd486d1..fee6551f0c 100644 --- a/modules/calib3d/test/test_precomp.hpp +++ b/modules/calib3d/test/test_precomp.hpp @@ -9,11 +9,11 @@ #ifndef __OPENCV_TEST_PRECOMP_HPP__ #define __OPENCV_TEST_PRECOMP_HPP__ -#include "opencv2/ts/ts.hpp" -#include "opencv2/imgproc/imgproc.hpp" +#include "opencv2/ts.hpp" +#include "opencv2/imgproc.hpp" #include "opencv2/imgproc/imgproc_c.h" -#include "opencv2/calib3d/calib3d.hpp" -#include "opencv2/highgui/highgui.hpp" +#include "opencv2/calib3d.hpp" +#include "opencv2/highgui.hpp" #include namespace cvtest diff --git a/modules/contrib/doc/facerec/colormaps.rst b/modules/contrib/doc/facerec/colormaps.rst index babd0acc5d..beba413fdb 100644 --- a/modules/contrib/doc/facerec/colormaps.rst +++ b/modules/contrib/doc/facerec/colormaps.rst @@ -42,9 +42,9 @@ In OpenCV 2.4 you only need :ocv:func:`applyColorMap` to apply a colormap on a g .. code-block:: cpp - #include - #include - #include + #include + #include + #include using namespace cv; diff --git a/modules/contrib/doc/facerec/src/facerec_demo.cpp b/modules/contrib/doc/facerec/src/facerec_demo.cpp index b1f3bdee40..e3d82b6f23 100644 --- a/modules/contrib/doc/facerec/src/facerec_demo.cpp +++ b/modules/contrib/doc/facerec/src/facerec_demo.cpp @@ -16,9 +16,9 @@ * See */ -#include "opencv2/core/core.hpp" -#include "opencv2/contrib/contrib.hpp" -#include "opencv2/highgui/highgui.hpp" +#include "opencv2/core.hpp" +#include "opencv2/contrib.hpp" +#include "opencv2/highgui.hpp" #include diff --git a/modules/contrib/doc/facerec/src/facerec_eigenfaces.cpp b/modules/contrib/doc/facerec/src/facerec_eigenfaces.cpp index b3d5f4dad7..9d28476324 100644 --- a/modules/contrib/doc/facerec/src/facerec_eigenfaces.cpp +++ b/modules/contrib/doc/facerec/src/facerec_eigenfaces.cpp @@ -16,9 +16,9 @@ * See */ -#include "opencv2/core/core.hpp" -#include "opencv2/contrib/contrib.hpp" -#include "opencv2/highgui/highgui.hpp" +#include "opencv2/core.hpp" +#include "opencv2/contrib.hpp" +#include "opencv2/highgui.hpp" #include #include diff --git a/modules/contrib/doc/facerec/src/facerec_fisherfaces.cpp b/modules/contrib/doc/facerec/src/facerec_fisherfaces.cpp index b88d90e50d..9e8988a6e5 100644 --- a/modules/contrib/doc/facerec/src/facerec_fisherfaces.cpp +++ b/modules/contrib/doc/facerec/src/facerec_fisherfaces.cpp @@ -16,9 +16,9 @@ * See */ -#include "opencv2/core/core.hpp" -#include "opencv2/contrib/contrib.hpp" -#include "opencv2/highgui/highgui.hpp" +#include "opencv2/core.hpp" +#include "opencv2/contrib.hpp" +#include "opencv2/highgui.hpp" #include #include diff --git a/modules/contrib/doc/facerec/src/facerec_lbph.cpp b/modules/contrib/doc/facerec/src/facerec_lbph.cpp index 03fe76d73a..1477777947 100644 --- a/modules/contrib/doc/facerec/src/facerec_lbph.cpp +++ b/modules/contrib/doc/facerec/src/facerec_lbph.cpp @@ -16,9 +16,9 @@ * See */ -#include "opencv2/core/core.hpp" -#include "opencv2/contrib/contrib.hpp" -#include "opencv2/highgui/highgui.hpp" +#include "opencv2/core.hpp" +#include "opencv2/contrib.hpp" +#include "opencv2/highgui.hpp" #include #include diff --git a/modules/contrib/doc/facerec/src/facerec_save_load.cpp b/modules/contrib/doc/facerec/src/facerec_save_load.cpp index d8e3104785..583b893b0d 100644 --- a/modules/contrib/doc/facerec/src/facerec_save_load.cpp +++ b/modules/contrib/doc/facerec/src/facerec_save_load.cpp @@ -16,9 +16,9 @@ * See */ -#include "opencv2/contrib/contrib.hpp" -#include "opencv2/core/core.hpp" -#include "opencv2/highgui/highgui.hpp" +#include "opencv2/contrib.hpp" +#include "opencv2/core.hpp" +#include "opencv2/highgui.hpp" #include #include diff --git a/modules/contrib/doc/facerec/src/facerec_video.cpp b/modules/contrib/doc/facerec/src/facerec_video.cpp index 7fc7cfaf5f..c22e416211 100644 --- a/modules/contrib/doc/facerec/src/facerec_video.cpp +++ b/modules/contrib/doc/facerec/src/facerec_video.cpp @@ -16,11 +16,11 @@ * See */ -#include "opencv2/core/core.hpp" -#include "opencv2/contrib/contrib.hpp" -#include "opencv2/highgui/highgui.hpp" -#include "opencv2/imgproc/imgproc.hpp" -#include "opencv2/objdetect/objdetect.hpp" +#include "opencv2/core.hpp" +#include "opencv2/contrib.hpp" +#include "opencv2/highgui.hpp" +#include "opencv2/imgproc.hpp" +#include "opencv2/objdetect.hpp" #include #include diff --git a/modules/contrib/include/opencv2/contrib/contrib.hpp b/modules/contrib/include/opencv2/contrib.hpp similarity index 99% rename from modules/contrib/include/opencv2/contrib/contrib.hpp rename to modules/contrib/include/opencv2/contrib.hpp index c303586cf6..44bf3313ed 100644 --- a/modules/contrib/include/opencv2/contrib/contrib.hpp +++ b/modules/contrib/include/opencv2/contrib.hpp @@ -43,10 +43,10 @@ #ifndef __OPENCV_CONTRIB_HPP__ #define __OPENCV_CONTRIB_HPP__ -#include "opencv2/core/core.hpp" -#include "opencv2/imgproc/imgproc.hpp" -#include "opencv2/features2d/features2d.hpp" -#include "opencv2/objdetect/objdetect.hpp" +#include "opencv2/core.hpp" +#include "opencv2/imgproc.hpp" +#include "opencv2/features2d.hpp" +#include "opencv2/objdetect.hpp" #ifdef __cplusplus @@ -972,4 +972,3 @@ namespace cv #endif #endif - diff --git a/modules/contrib/include/opencv2/contrib/detection_based_tracker.hpp b/modules/contrib/include/opencv2/contrib/detection_based_tracker.hpp index be122a6da9..c3db03ab9f 100644 --- a/modules/contrib/include/opencv2/contrib/detection_based_tracker.hpp +++ b/modules/contrib/include/opencv2/contrib/detection_based_tracker.hpp @@ -2,8 +2,8 @@ #if defined(__linux__) || defined(LINUX) || defined(__APPLE__) || defined(ANDROID) -#include -#include +#include +#include #include diff --git a/modules/contrib/include/opencv2/contrib/hybridtracker.hpp b/modules/contrib/include/opencv2/contrib/hybridtracker.hpp index cd99b7308c..20f9224e43 100644 --- a/modules/contrib/include/opencv2/contrib/hybridtracker.hpp +++ b/modules/contrib/include/opencv2/contrib/hybridtracker.hpp @@ -43,12 +43,11 @@ #ifndef __OPENCV_HYBRIDTRACKER_H_ #define __OPENCV_HYBRIDTRACKER_H_ -#include "opencv2/core/core.hpp" -#include "opencv2/core/operations.hpp" -#include "opencv2/imgproc/imgproc.hpp" -#include "opencv2/features2d/features2d.hpp" +#include "opencv2/core.hpp" +#include "opencv2/imgproc.hpp" +#include "opencv2/features2d.hpp" #include "opencv2/video/tracking.hpp" -#include "opencv2/ml/ml.hpp" +#include "opencv2/ml.hpp" #ifdef __cplusplus diff --git a/modules/contrib/include/opencv2/contrib/openfabmap.hpp b/modules/contrib/include/opencv2/contrib/openfabmap.hpp index e73bbb953d..38597755a8 100644 --- a/modules/contrib/include/opencv2/contrib/openfabmap.hpp +++ b/modules/contrib/include/opencv2/contrib/openfabmap.hpp @@ -52,8 +52,8 @@ #ifndef __OPENCV_OPENFABMAP_H_ #define __OPENCV_OPENFABMAP_H_ -#include "opencv2/core/core.hpp" -#include "opencv2/features2d/features2d.hpp" +#include "opencv2/core.hpp" +#include "opencv2/features2d.hpp" #include #include diff --git a/modules/contrib/include/opencv2/contrib/retina.hpp b/modules/contrib/include/opencv2/contrib/retina.hpp index 6f660efcac..456daab443 100644 --- a/modules/contrib/include/opencv2/contrib/retina.hpp +++ b/modules/contrib/include/opencv2/contrib/retina.hpp @@ -72,7 +72,7 @@ * Author: Alexandre Benoit */ -#include "opencv2/core/core.hpp" // for all OpenCV core functionalities access, including cv::Exception support +#include "opencv2/core.hpp" // for all OpenCV core functionalities access, including cv::Exception support #include namespace cv diff --git a/modules/contrib/src/ba.cpp b/modules/contrib/src/ba.cpp index 9b64ba4d2e..39acd45798 100644 --- a/modules/contrib/src/ba.cpp +++ b/modules/contrib/src/ba.cpp @@ -40,7 +40,7 @@ //M*/ #include "precomp.hpp" -#include "opencv2/calib3d/calib3d.hpp" +#include "opencv2/calib3d.hpp" #include using namespace cv; diff --git a/modules/contrib/src/chamfermatching.cpp b/modules/contrib/src/chamfermatching.cpp index a23ca8a8c3..bd30ad9916 100644 --- a/modules/contrib/src/chamfermatching.cpp +++ b/modules/contrib/src/chamfermatching.cpp @@ -46,7 +46,7 @@ #include "precomp.hpp" #include "opencv2/opencv_modules.hpp" #ifdef HAVE_OPENCV_HIGHGUI -# include "opencv2/highgui/highgui.hpp" +# include "opencv2/highgui.hpp" #endif #include #include diff --git a/modules/contrib/src/featuretracker.cpp b/modules/contrib/src/featuretracker.cpp index 712b2d5694..575f69abf9 100644 --- a/modules/contrib/src/featuretracker.cpp +++ b/modules/contrib/src/featuretracker.cpp @@ -42,7 +42,7 @@ #include "precomp.hpp" #include #include -#include "opencv2/calib3d/calib3d.hpp" +#include "opencv2/calib3d.hpp" #include "opencv2/contrib/hybridtracker.hpp" using namespace cv; diff --git a/modules/contrib/src/gencolors.cpp b/modules/contrib/src/gencolors.cpp index 42fc411e20..504015308c 100644 --- a/modules/contrib/src/gencolors.cpp +++ b/modules/contrib/src/gencolors.cpp @@ -39,7 +39,6 @@ // the use of this software, even if advised of the possibility of such damage. // //M*/ -#include "opencv2/core/core.hpp" #include "precomp.hpp" #include diff --git a/modules/contrib/src/inputoutput.cpp b/modules/contrib/src/inputoutput.cpp index d10d884c83..ee97e1287b 100644 --- a/modules/contrib/src/inputoutput.cpp +++ b/modules/contrib/src/inputoutput.cpp @@ -1,5 +1,5 @@ -#include "opencv2/contrib/contrib.hpp" +#include "opencv2/contrib.hpp" #ifdef WIN32 #include diff --git a/modules/contrib/src/precomp.hpp b/modules/contrib/src/precomp.hpp index 7c8e6bdf81..7819148ddc 100644 --- a/modules/contrib/src/precomp.hpp +++ b/modules/contrib/src/precomp.hpp @@ -47,10 +47,10 @@ #include "cvconfig.h" #endif -#include "opencv2/contrib/contrib.hpp" -#include "opencv2/features2d/features2d.hpp" -#include "opencv2/objdetect/objdetect.hpp" -#include "opencv2/imgproc/imgproc.hpp" +#include "opencv2/contrib.hpp" +#include "opencv2/features2d.hpp" +#include "opencv2/objdetect.hpp" +#include "opencv2/imgproc.hpp" #include "opencv2/imgproc/imgproc_c.h" #include "opencv2/core/internal.hpp" diff --git a/modules/contrib/src/rgbdodometry.cpp b/modules/contrib/src/rgbdodometry.cpp index 3289b35124..1fa800b0ae 100644 --- a/modules/contrib/src/rgbdodometry.cpp +++ b/modules/contrib/src/rgbdodometry.cpp @@ -44,11 +44,11 @@ #define SHOW_DEBUG_IMAGES 0 -#include "opencv2/core/core.hpp" -#include "opencv2/calib3d/calib3d.hpp" +#include "opencv2/core.hpp" +#include "opencv2/calib3d.hpp" #if SHOW_DEBUG_IMAGES -# include "opencv2/highgui/highgui.hpp" +# include "opencv2/highgui.hpp" #endif #include diff --git a/modules/contrib/test/test_precomp.hpp b/modules/contrib/test/test_precomp.hpp index d477eddbbe..de9e283ee2 100644 --- a/modules/contrib/test/test_precomp.hpp +++ b/modules/contrib/test/test_precomp.hpp @@ -9,8 +9,8 @@ #ifndef __OPENCV_TEST_PRECOMP_HPP__ #define __OPENCV_TEST_PRECOMP_HPP__ -#include "opencv2/ts/ts.hpp" -#include "opencv2/contrib/contrib.hpp" +#include "opencv2/ts.hpp" +#include "opencv2/contrib.hpp" #include #endif diff --git a/modules/core/doc/basic_structures.rst b/modules/core/doc/basic_structures.rst index ca9f5e21a2..d9cc303315 100644 --- a/modules/core/doc/basic_structures.rst +++ b/modules/core/doc/basic_structures.rst @@ -2425,7 +2425,7 @@ The class provides the following features for all derived classes: Here is example of SIFT use in your application via Algorithm interface: :: #include "opencv2/opencv.hpp" - #include "opencv2/nonfree/nonfree.hpp" + #include "opencv2/nonfree.hpp" ... diff --git a/modules/core/doc/intro.rst b/modules/core/doc/intro.rst index a67236500b..806f434b26 100644 --- a/modules/core/doc/intro.rst +++ b/modules/core/doc/intro.rst @@ -30,14 +30,14 @@ All the OpenCV classes and functions are placed into the ``cv`` namespace. There .. code-block:: c - #include "opencv2/core/core.hpp" + #include "opencv2/core.hpp" ... cv::Mat H = cv::findHomography(points1, points2, CV_RANSAC, 5); ... or :: - #include "opencv2/core/core.hpp" + #include "opencv2/core.hpp" using namespace cv; ... Mat H = findHomography(points1, points2, CV_RANSAC, 5 ); diff --git a/modules/core/include/opencv2/core/core.hpp b/modules/core/include/opencv2/core.hpp similarity index 99% rename from modules/core/include/opencv2/core/core.hpp rename to modules/core/include/opencv2/core.hpp index 1efd4c85c6..556a3065d9 100644 --- a/modules/core/include/opencv2/core/core.hpp +++ b/modules/core/include/opencv2/core.hpp @@ -3143,8 +3143,8 @@ public: void deallocate(); //! resizes the buffer and preserves the content void resize(size_t _size); - //! returns the current buffer size - size_t size() const; + //! returns the current buffer size + size_t size() const; //! returns pointer to the real buffer, stack-allocated or head-allocated operator _Tp* (); //! returns read-only pointer to the real buffer, stack-allocated or head-allocated diff --git a/modules/core/include/opencv2/core/eigen.hpp b/modules/core/include/opencv2/core/eigen.hpp index 49bd36ba3b..6e47206c54 100644 --- a/modules/core/include/opencv2/core/eigen.hpp +++ b/modules/core/include/opencv2/core/eigen.hpp @@ -46,7 +46,7 @@ #ifdef __cplusplus #include "opencv2/core/core_c.h" -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" #if defined _MSC_VER && _MSC_VER >= 1200 #pragma warning( disable: 4714 ) //__forceinline is not inlined diff --git a/modules/core/include/opencv2/core/gpumat.hpp b/modules/core/include/opencv2/core/gpumat.hpp index d39f0a82d7..be757a935b 100644 --- a/modules/core/include/opencv2/core/gpumat.hpp +++ b/modules/core/include/opencv2/core/gpumat.hpp @@ -45,7 +45,7 @@ #ifdef __cplusplus -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" #include "opencv2/core/cuda_devptrs.hpp" namespace cv { namespace gpu diff --git a/modules/core/include/opencv2/core/opengl_interop.hpp b/modules/core/include/opencv2/core/opengl.hpp similarity index 99% rename from modules/core/include/opencv2/core/opengl_interop.hpp rename to modules/core/include/opencv2/core/opengl.hpp index 857646e1a0..1643d39e0c 100644 --- a/modules/core/include/opencv2/core/opengl_interop.hpp +++ b/modules/core/include/opencv2/core/opengl.hpp @@ -45,7 +45,7 @@ #ifdef __cplusplus -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" namespace cv { namespace ogl { diff --git a/modules/core/perf/perf_precomp.hpp b/modules/core/perf/perf_precomp.hpp index 4d5d9886e3..cea1c1308f 100644 --- a/modules/core/perf/perf_precomp.hpp +++ b/modules/core/perf/perf_precomp.hpp @@ -9,7 +9,7 @@ #ifndef __OPENCV_PERF_PRECOMP_HPP__ #define __OPENCV_PERF_PRECOMP_HPP__ -#include "opencv2/ts/ts.hpp" +#include "opencv2/ts.hpp" #ifdef GTEST_CREATE_SHARED_LIBRARY #error no modules except ts should have GTEST_CREATE_SHARED_LIBRARY defined diff --git a/modules/core/src/gl_core_3_1.cpp b/modules/core/src/gl_core_3_1.cpp index 3bc74faa19..61006f5cac 100644 --- a/modules/core/src/gl_core_3_1.cpp +++ b/modules/core/src/gl_core_3_1.cpp @@ -1,7 +1,7 @@ #include #include #include "cvconfig.h" -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" #include "gl_core_3_1.hpp" #ifdef HAVE_OPENGL diff --git a/modules/core/src/matrix.cpp b/modules/core/src/matrix.cpp index 440958114a..8336a28683 100644 --- a/modules/core/src/matrix.cpp +++ b/modules/core/src/matrix.cpp @@ -42,7 +42,7 @@ #include "precomp.hpp" #include "opencv2/core/gpumat.hpp" -#include "opencv2/core/opengl_interop.hpp" +#include "opencv2/core/opengl.hpp" /****************************************************************************************\ * [scaled] Identity matrix initialization * diff --git a/modules/core/src/opengl_interop.cpp b/modules/core/src/opengl_interop.cpp index 4c05f9f84b..cf2cc47cfb 100644 --- a/modules/core/src/opengl_interop.cpp +++ b/modules/core/src/opengl_interop.cpp @@ -41,7 +41,7 @@ //M*/ #include "precomp.hpp" -#include "opencv2/core/opengl_interop.hpp" +#include "opencv2/core/opengl.hpp" #include "opencv2/core/gpumat.hpp" #ifdef HAVE_OPENGL diff --git a/modules/core/src/precomp.hpp b/modules/core/src/precomp.hpp index 84f7f5e2be..edfbda65e9 100644 --- a/modules/core/src/precomp.hpp +++ b/modules/core/src/precomp.hpp @@ -47,7 +47,7 @@ #include "cvconfig.h" #endif -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" #include "opencv2/core/core_c.h" #include "opencv2/core/internal.hpp" diff --git a/modules/core/test/test_precomp.hpp b/modules/core/test/test_precomp.hpp index 5cbe1c8f99..6c0f493d4e 100644 --- a/modules/core/test/test_precomp.hpp +++ b/modules/core/test/test_precomp.hpp @@ -9,7 +9,7 @@ #ifndef __OPENCV_TEST_PRECOMP_HPP__ #define __OPENCV_TEST_PRECOMP_HPP__ -#include "opencv2/ts/ts.hpp" +#include "opencv2/ts.hpp" #include "opencv2/core/core_c.h" #include diff --git a/modules/features2d/include/opencv2/features2d/features2d.hpp b/modules/features2d/include/opencv2/features2d.hpp similarity index 99% rename from modules/features2d/include/opencv2/features2d/features2d.hpp rename to modules/features2d/include/opencv2/features2d.hpp index d252071071..8f32445ca2 100644 --- a/modules/features2d/include/opencv2/features2d/features2d.hpp +++ b/modules/features2d/include/opencv2/features2d.hpp @@ -43,7 +43,7 @@ #ifndef __OPENCV_FEATURES_2D_HPP__ #define __OPENCV_FEATURES_2D_HPP__ -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" #include "opencv2/flann/miniflann.hpp" #ifdef __cplusplus diff --git a/modules/features2d/perf/perf_precomp.hpp b/modules/features2d/perf/perf_precomp.hpp index c3f98c2176..30607daaf6 100644 --- a/modules/features2d/perf/perf_precomp.hpp +++ b/modules/features2d/perf/perf_precomp.hpp @@ -9,9 +9,9 @@ #ifndef __OPENCV_PERF_PRECOMP_HPP__ #define __OPENCV_PERF_PRECOMP_HPP__ -#include "opencv2/ts/ts.hpp" -#include "opencv2/highgui/highgui.hpp" -#include "opencv2/features2d/features2d.hpp" +#include "opencv2/ts.hpp" +#include "opencv2/highgui.hpp" +#include "opencv2/features2d.hpp" #ifdef GTEST_CREATE_SHARED_LIBRARY #error no modules except ts should have GTEST_CREATE_SHARED_LIBRARY defined diff --git a/modules/features2d/src/blobdetector.cpp b/modules/features2d/src/blobdetector.cpp index 735fe6e78a..3f50f3c1af 100644 --- a/modules/features2d/src/blobdetector.cpp +++ b/modules/features2d/src/blobdetector.cpp @@ -48,7 +48,7 @@ #ifdef DEBUG_BLOB_DETECTOR # include "opencv2/opencv_modules.hpp" # ifdef HAVE_OPENCV_HIGHGUI -# include "opencv2/highgui/highgui.hpp" +# include "opencv2/highgui.hpp" # else # undef DEBUG_BLOB_DETECTOR # endif diff --git a/modules/features2d/src/brisk.cpp b/modules/features2d/src/brisk.cpp index 0e67e4d0f0..6709449fa5 100644 --- a/modules/features2d/src/brisk.cpp +++ b/modules/features2d/src/brisk.cpp @@ -42,9 +42,9 @@ the IEEE International Conference on Computer Vision (ICCV2011). */ -#include -#include -#include +#include +#include +#include #include #include diff --git a/modules/features2d/src/precomp.hpp b/modules/features2d/src/precomp.hpp index cbc1eb690a..62936b48f3 100644 --- a/modules/features2d/src/precomp.hpp +++ b/modules/features2d/src/precomp.hpp @@ -47,8 +47,8 @@ #include "cvconfig.h" #endif -#include "opencv2/features2d/features2d.hpp" -#include "opencv2/imgproc/imgproc.hpp" +#include "opencv2/features2d.hpp" +#include "opencv2/imgproc.hpp" #include "opencv2/imgproc/imgproc_c.h" #include "opencv2/core/internal.hpp" diff --git a/modules/features2d/test/test_descriptors_regression.cpp b/modules/features2d/test/test_descriptors_regression.cpp index 2185625ae9..193545162b 100644 --- a/modules/features2d/test/test_descriptors_regression.cpp +++ b/modules/features2d/test/test_descriptors_regression.cpp @@ -40,7 +40,7 @@ //M*/ #include "test_precomp.hpp" -#include "opencv2/highgui/highgui.hpp" +#include "opencv2/highgui.hpp" using namespace std; using namespace cv; diff --git a/modules/features2d/test/test_detectors_regression.cpp b/modules/features2d/test/test_detectors_regression.cpp index e5e8712cef..9a88c42f7b 100644 --- a/modules/features2d/test/test_detectors_regression.cpp +++ b/modules/features2d/test/test_detectors_regression.cpp @@ -40,7 +40,7 @@ //M*/ #include "test_precomp.hpp" -#include "opencv2/highgui/highgui.hpp" +#include "opencv2/highgui.hpp" using namespace std; using namespace cv; diff --git a/modules/features2d/test/test_keypoints.cpp b/modules/features2d/test/test_keypoints.cpp index b5d01a7378..7bc5c6e9a2 100644 --- a/modules/features2d/test/test_keypoints.cpp +++ b/modules/features2d/test/test_keypoints.cpp @@ -40,7 +40,7 @@ //M*/ #include "test_precomp.hpp" -#include "opencv2/highgui/highgui.hpp" +#include "opencv2/highgui.hpp" using namespace std; using namespace cv; diff --git a/modules/features2d/test/test_matchers_algorithmic.cpp b/modules/features2d/test/test_matchers_algorithmic.cpp index d76715dd95..a15578a1db 100644 --- a/modules/features2d/test/test_matchers_algorithmic.cpp +++ b/modules/features2d/test/test_matchers_algorithmic.cpp @@ -40,7 +40,7 @@ //M*/ #include "test_precomp.hpp" -#include "opencv2/highgui/highgui.hpp" +#include "opencv2/highgui.hpp" using namespace std; using namespace cv; diff --git a/modules/features2d/test/test_orb.cpp b/modules/features2d/test/test_orb.cpp index 4ec841a2f9..aa8cdbdc67 100644 --- a/modules/features2d/test/test_orb.cpp +++ b/modules/features2d/test/test_orb.cpp @@ -40,7 +40,7 @@ //M*/ #include "test_precomp.hpp" -#include "opencv2/highgui/highgui.hpp" +#include "opencv2/highgui.hpp" using namespace std; using namespace cv; diff --git a/modules/features2d/test/test_precomp.hpp b/modules/features2d/test/test_precomp.hpp index bc2d8be6e9..979e7c78cb 100644 --- a/modules/features2d/test/test_precomp.hpp +++ b/modules/features2d/test/test_precomp.hpp @@ -9,11 +9,11 @@ #ifndef __OPENCV_TEST_PRECOMP_HPP__ #define __OPENCV_TEST_PRECOMP_HPP__ -#include "opencv2/ts/ts.hpp" -#include "opencv2/imgproc/imgproc.hpp" +#include "opencv2/ts.hpp" +#include "opencv2/imgproc.hpp" #include "opencv2/imgproc/imgproc_c.h" -#include "opencv2/features2d/features2d.hpp" -#include "opencv2/highgui/highgui.hpp" +#include "opencv2/features2d.hpp" +#include "opencv2/highgui.hpp" #include #endif diff --git a/modules/features2d/test/test_rotation_and_scale_invariance.cpp b/modules/features2d/test/test_rotation_and_scale_invariance.cpp index e843ffe719..1f67da17be 100644 --- a/modules/features2d/test/test_rotation_and_scale_invariance.cpp +++ b/modules/features2d/test/test_rotation_and_scale_invariance.cpp @@ -40,7 +40,7 @@ //M*/ #include "test_precomp.hpp" -#include "opencv2/highgui/highgui.hpp" +#include "opencv2/highgui.hpp" using namespace std; using namespace cv; diff --git a/modules/flann/include/opencv2/flann/flann.hpp b/modules/flann/include/opencv2/flann.hpp similarity index 99% rename from modules/flann/include/opencv2/flann/flann.hpp rename to modules/flann/include/opencv2/flann.hpp index 8a238933df..d5eedcc0f0 100644 --- a/modules/flann/include/opencv2/flann/flann.hpp +++ b/modules/flann/include/opencv2/flann.hpp @@ -46,7 +46,7 @@ #ifdef __cplusplus #include "opencv2/core/types_c.h" -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" #include "opencv2/flann/flann_base.hpp" #include "opencv2/flann/miniflann.hpp" diff --git a/modules/flann/include/opencv2/flann/miniflann.hpp b/modules/flann/include/opencv2/flann/miniflann.hpp index 18c908141d..475335ca39 100644 --- a/modules/flann/include/opencv2/flann/miniflann.hpp +++ b/modules/flann/include/opencv2/flann/miniflann.hpp @@ -45,7 +45,7 @@ #ifdef __cplusplus -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" #include "opencv2/flann/defines.h" namespace cv diff --git a/modules/flann/include/opencv2/flann/timer.h b/modules/flann/include/opencv2/flann/timer.h index 6428b0a0d7..58354e75dd 100644 --- a/modules/flann/include/opencv2/flann/timer.h +++ b/modules/flann/include/opencv2/flann/timer.h @@ -32,7 +32,7 @@ #define OPENCV_FLANN_TIMER_H #include -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" namespace cvflann { diff --git a/modules/flann/src/flann.cpp b/modules/flann/src/flann.cpp index fa1fdaf418..43d0e1f2a0 100644 --- a/modules/flann/src/flann.cpp +++ b/modules/flann/src/flann.cpp @@ -27,7 +27,7 @@ *************************************************************************/ #include "precomp.hpp" -#include "opencv2/flann/flann.hpp" +#include "opencv2/flann.hpp" namespace cvflann { diff --git a/modules/flann/src/precomp.hpp b/modules/flann/src/precomp.hpp index fb5ee3f982..0d2647932b 100644 --- a/modules/flann/src/precomp.hpp +++ b/modules/flann/src/precomp.hpp @@ -8,7 +8,7 @@ #ifdef HAVE_CVCONFIG_H # include "cvconfig.h" #endif -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" #include "opencv2/core/internal.hpp" #include "opencv2/flann/miniflann.hpp" diff --git a/modules/flann/test/test_precomp.hpp b/modules/flann/test/test_precomp.hpp index 809a97e702..b5cd174610 100644 --- a/modules/flann/test/test_precomp.hpp +++ b/modules/flann/test/test_precomp.hpp @@ -9,9 +9,9 @@ #ifndef __OPENCV_TEST_PRECOMP_HPP__ #define __OPENCV_TEST_PRECOMP_HPP__ -#include "opencv2/ts/ts.hpp" -#include "opencv2/core/core.hpp" -#include "opencv2/flann/flann.hpp" +#include "opencv2/ts.hpp" +#include "opencv2/core.hpp" +#include "opencv2/flann.hpp" #include #endif diff --git a/modules/gpu/CMakeLists.txt b/modules/gpu/CMakeLists.txt index 26bf624c66..26f806fb89 100644 --- a/modules/gpu/CMakeLists.txt +++ b/modules/gpu/CMakeLists.txt @@ -7,7 +7,7 @@ ocv_add_module(gpu opencv_imgproc opencv_calib3d opencv_objdetect opencv_video o ocv_module_include_directories("${CMAKE_CURRENT_SOURCE_DIR}/src/cuda") -file(GLOB lib_hdrs "include/opencv2/${name}/*.hpp" "include/opencv2/${name}/*.h") +file(GLOB lib_hdrs "include/opencv2/*.hpp" "include/opencv2/${name}/*.hpp" "include/opencv2/${name}/*.h") file(GLOB lib_device_hdrs "include/opencv2/${name}/device/*.hpp" "include/opencv2/${name}/device/*.h") file(GLOB lib_device_hdrs_detail "include/opencv2/${name}/device/detail/*.hpp" "include/opencv2/${name}/device/detail/*.h") file(GLOB lib_int_hdrs "src/*.hpp" "src/*.h") diff --git a/modules/gpu/app/nv_perf_test/main.cpp b/modules/gpu/app/nv_perf_test/main.cpp index ff15581e80..4bdf387edf 100644 --- a/modules/gpu/app/nv_perf_test/main.cpp +++ b/modules/gpu/app/nv_perf_test/main.cpp @@ -1,12 +1,11 @@ #include #define HAVE_CUDA 1 -#include -#include -#include -#include -#include -#include -#include +#include +#include +#include +#include +#include +#include static void printOsInfo() { diff --git a/modules/gpu/include/opencv2/gpu/gpu.hpp b/modules/gpu/include/opencv2/gpu.hpp similarity index 99% rename from modules/gpu/include/opencv2/gpu/gpu.hpp rename to modules/gpu/include/opencv2/gpu.hpp index 96d028ac33..ebf764f637 100644 --- a/modules/gpu/include/opencv2/gpu/gpu.hpp +++ b/modules/gpu/include/opencv2/gpu.hpp @@ -50,9 +50,9 @@ #endif #include "opencv2/core/gpumat.hpp" -#include "opencv2/imgproc/imgproc.hpp" -#include "opencv2/objdetect/objdetect.hpp" -#include "opencv2/features2d/features2d.hpp" +#include "opencv2/imgproc.hpp" +#include "opencv2/objdetect.hpp" +#include "opencv2/features2d.hpp" namespace cv { namespace gpu { diff --git a/modules/gpu/include/opencv2/gpu/stream_accessor.hpp b/modules/gpu/include/opencv2/gpu/stream_accessor.hpp index 6a1a0bddd5..abafc613d7 100644 --- a/modules/gpu/include/opencv2/gpu/stream_accessor.hpp +++ b/modules/gpu/include/opencv2/gpu/stream_accessor.hpp @@ -43,7 +43,7 @@ #ifndef __OPENCV_GPU_STREAM_ACCESSOR_HPP__ #define __OPENCV_GPU_STREAM_ACCESSOR_HPP__ -#include "opencv2/gpu/gpu.hpp" +#include "opencv2/gpu.hpp" #include "cuda_runtime_api.h" namespace cv diff --git a/modules/gpu/perf/perf_precomp.hpp b/modules/gpu/perf/perf_precomp.hpp index 4dca93c442..71fe9e7d07 100644 --- a/modules/gpu/perf/perf_precomp.hpp +++ b/modules/gpu/perf/perf_precomp.hpp @@ -18,18 +18,17 @@ #include #endif -#include "opencv2/ts/ts.hpp" -#include "opencv2/ts/ts_perf.hpp" +#include "opencv2/ts.hpp" -#include "opencv2/core/core.hpp" -#include "opencv2/highgui/highgui.hpp" -#include "opencv2/gpu/gpu.hpp" -#include "opencv2/calib3d/calib3d.hpp" -#include "opencv2/imgproc/imgproc.hpp" -#include "opencv2/video/video.hpp" -#include "opencv2/nonfree/nonfree.hpp" -#include "opencv2/legacy/legacy.hpp" -#include "opencv2/photo/photo.hpp" +#include "opencv2/core.hpp" +#include "opencv2/highgui.hpp" +#include "opencv2/gpu.hpp" +#include "opencv2/calib3d.hpp" +#include "opencv2/imgproc.hpp" +#include "opencv2/video.hpp" +#include "opencv2/nonfree.hpp" +#include "opencv2/legacy.hpp" +#include "opencv2/photo.hpp" #include "utility.hpp" diff --git a/modules/gpu/perf/utility.hpp b/modules/gpu/perf/utility.hpp index cff4cdd77d..18c85854ac 100644 --- a/modules/gpu/perf/utility.hpp +++ b/modules/gpu/perf/utility.hpp @@ -1,8 +1,8 @@ #ifndef __OPENCV_PERF_GPU_UTILITY_HPP__ #define __OPENCV_PERF_GPU_UTILITY_HPP__ -#include "opencv2/core/core.hpp" -#include "opencv2/imgproc/imgproc.hpp" +#include "opencv2/core.hpp" +#include "opencv2/imgproc.hpp" #include "opencv2/ts/ts_perf.hpp" cv::Mat readImage(const std::string& fileName, int flags = cv::IMREAD_COLOR); diff --git a/modules/gpu/perf4au/main.cpp b/modules/gpu/perf4au/main.cpp index 80d97ea806..f4a04432b5 100644 --- a/modules/gpu/perf4au/main.cpp +++ b/modules/gpu/perf4au/main.cpp @@ -2,13 +2,12 @@ #ifdef HAVE_CVCONFIG_H #include "cvconfig.h" #endif -#include "opencv2/core/core.hpp" -#include "opencv2/gpu/gpu.hpp" -#include "opencv2/highgui/highgui.hpp" -#include "opencv2/video/video.hpp" -#include "opencv2/legacy/legacy.hpp" -#include "opencv2/ts/ts.hpp" -#include "opencv2/ts/ts_perf.hpp" +#include "opencv2/core.hpp" +#include "opencv2/gpu.hpp" +#include "opencv2/highgui.hpp" +#include "opencv2/video.hpp" +#include "opencv2/legacy.hpp" +#include "opencv2/ts.hpp" static void printOsInfo() { diff --git a/modules/gpu/src/precomp.hpp b/modules/gpu/src/precomp.hpp index 7c53185107..1aa442b99b 100644 --- a/modules/gpu/src/precomp.hpp +++ b/modules/gpu/src/precomp.hpp @@ -66,12 +66,12 @@ #include #include -#include "opencv2/gpu/gpu.hpp" -#include "opencv2/imgproc/imgproc.hpp" +#include "opencv2/gpu.hpp" +#include "opencv2/imgproc.hpp" #include "opencv2/imgproc/imgproc_c.h" -#include "opencv2/calib3d/calib3d.hpp" +#include "opencv2/calib3d.hpp" #include "opencv2/core/internal.hpp" -#include "opencv2/video/video.hpp" +#include "opencv2/video.hpp" #if defined WIN32 || defined WINCE #include diff --git a/modules/gpu/test/interpolation.hpp b/modules/gpu/test/interpolation.hpp index 8e723c5c08..9ad08b1652 100644 --- a/modules/gpu/test/interpolation.hpp +++ b/modules/gpu/test/interpolation.hpp @@ -42,8 +42,8 @@ #ifndef __OPENCV_TEST_INTERPOLATION_HPP__ #define __OPENCV_TEST_INTERPOLATION_HPP__ -#include "opencv2/core/core.hpp" -#include "opencv2/imgproc/imgproc.hpp" +#include "opencv2/core.hpp" +#include "opencv2/imgproc.hpp" template T readVal(const cv::Mat& src, int y, int x, int c, int border_type, cv::Scalar borderVal = cv::Scalar()) { diff --git a/modules/gpu/test/nvidia/NCVTestSourceProvider.hpp b/modules/gpu/test/nvidia/NCVTestSourceProvider.hpp index 0413fa563c..0ae104c96c 100644 --- a/modules/gpu/test/nvidia/NCVTestSourceProvider.hpp +++ b/modules/gpu/test/nvidia/NCVTestSourceProvider.hpp @@ -14,7 +14,7 @@ #include #include "NCV.hpp" -#include +#include template diff --git a/modules/gpu/test/test_precomp.hpp b/modules/gpu/test/test_precomp.hpp index e7ade6aed7..93c1df04d5 100644 --- a/modules/gpu/test/test_precomp.hpp +++ b/modules/gpu/test/test_precomp.hpp @@ -69,17 +69,16 @@ #include #include - #include "opencv2/core/core.hpp" - #include "opencv2/core/opengl_interop.hpp" - #include "opencv2/highgui/highgui.hpp" - #include "opencv2/calib3d/calib3d.hpp" - #include "opencv2/imgproc/imgproc.hpp" - #include "opencv2/video/video.hpp" - #include "opencv2/ts/ts.hpp" - #include "opencv2/ts/ts_perf.hpp" - #include "opencv2/gpu/gpu.hpp" - #include "opencv2/nonfree/nonfree.hpp" - #include "opencv2/legacy/legacy.hpp" + #include "opencv2/core.hpp" + #include "opencv2/core/opengl.hpp" + #include "opencv2/highgui.hpp" + #include "opencv2/calib3d.hpp" + #include "opencv2/imgproc.hpp" + #include "opencv2/video.hpp" + #include "opencv2/ts.hpp" + #include "opencv2/gpu.hpp" + #include "opencv2/nonfree.hpp" + #include "opencv2/legacy.hpp" #include "utility.hpp" #include "interpolation.hpp" diff --git a/modules/gpu/test/utility.hpp b/modules/gpu/test/utility.hpp index 674e9a17ee..fa0cd93e7c 100644 --- a/modules/gpu/test/utility.hpp +++ b/modules/gpu/test/utility.hpp @@ -42,11 +42,10 @@ #ifndef __OPENCV_GPU_TEST_UTILITY_HPP__ #define __OPENCV_GPU_TEST_UTILITY_HPP__ -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" #include "opencv2/core/gpumat.hpp" -#include "opencv2/highgui/highgui.hpp" -#include "opencv2/ts/ts.hpp" -#include "opencv2/ts/ts_perf.hpp" +#include "opencv2/highgui.hpp" +#include "opencv2/ts.hpp" ////////////////////////////////////////////////////////////////////// // random generators diff --git a/modules/highgui/CMakeLists.txt b/modules/highgui/CMakeLists.txt index bc6d0e9f61..8d3056742a 100644 --- a/modules/highgui/CMakeLists.txt +++ b/modules/highgui/CMakeLists.txt @@ -74,7 +74,7 @@ set(highgui_srcs src/window.cpp ) -file(GLOB highgui_ext_hdrs "include/opencv2/${name}/*.hpp" "include/opencv2/${name}/*.h") +file(GLOB highgui_ext_hdrs "include/opencv2/*.hpp" "include/opencv2/${name}/*.hpp" "include/opencv2/${name}/*.h") if(HAVE_QT) if (HAVE_QT_OPENGL) diff --git a/modules/highgui/include/opencv2/highgui/highgui.hpp b/modules/highgui/include/opencv2/highgui.hpp similarity index 99% rename from modules/highgui/include/opencv2/highgui/highgui.hpp rename to modules/highgui/include/opencv2/highgui.hpp index 1c41b52812..0b1c617cd3 100644 --- a/modules/highgui/include/opencv2/highgui/highgui.hpp +++ b/modules/highgui/include/opencv2/highgui.hpp @@ -43,7 +43,7 @@ #ifndef __OPENCV_HIGHGUI_HPP__ #define __OPENCV_HIGHGUI_HPP__ -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" #include "opencv2/highgui/highgui_c.h" #ifdef __cplusplus diff --git a/modules/highgui/include/opencv2/highgui/cap_ios.h b/modules/highgui/include/opencv2/highgui/cap_ios.h index 5bd5fe3c67..97d9a08af6 100644 --- a/modules/highgui/include/opencv2/highgui/cap_ios.h +++ b/modules/highgui/include/opencv2/highgui/cap_ios.h @@ -32,7 +32,7 @@ #import #import #import -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" /////////////////////////////////////// CvAbstractCamera ///////////////////////////////////// diff --git a/modules/highgui/perf/perf_precomp.hpp b/modules/highgui/perf/perf_precomp.hpp index ec8a447fa1..30e9b7ff6d 100644 --- a/modules/highgui/perf/perf_precomp.hpp +++ b/modules/highgui/perf/perf_precomp.hpp @@ -9,8 +9,8 @@ #ifndef __OPENCV_PERF_PRECOMP_HPP__ #define __OPENCV_PERF_PRECOMP_HPP__ -#include "opencv2/ts/ts.hpp" -#include "opencv2/highgui/highgui.hpp" +#include "opencv2/ts.hpp" +#include "opencv2/highgui.hpp" #ifdef GTEST_CREATE_SHARED_LIBRARY #error no modules except ts should have GTEST_CREATE_SHARED_LIBRARY defined diff --git a/modules/highgui/src/cap_android.cpp b/modules/highgui/src/cap_android.cpp index 2f3f388c04..082a12f008 100644 --- a/modules/highgui/src/cap_android.cpp +++ b/modules/highgui/src/cap_android.cpp @@ -43,7 +43,7 @@ #ifdef HAVE_ANDROID_NATIVE_CAMERA -#include +#include #include #include #include diff --git a/modules/highgui/src/cap_avfoundation.mm b/modules/highgui/src/cap_avfoundation.mm index a2451a1bfd..c7471e2e86 100644 --- a/modules/highgui/src/cap_avfoundation.mm +++ b/modules/highgui/src/cap_avfoundation.mm @@ -30,7 +30,7 @@ */ #include "precomp.hpp" -#include "opencv2/imgproc/imgproc.hpp" +#include "opencv2/imgproc.hpp" #include #import #import diff --git a/modules/highgui/src/cap_ffmpeg_impl.hpp b/modules/highgui/src/cap_ffmpeg_impl.hpp index cfb2e4fa10..870804dd88 100644 --- a/modules/highgui/src/cap_ffmpeg_impl.hpp +++ b/modules/highgui/src/cap_ffmpeg_impl.hpp @@ -59,11 +59,11 @@ extern "C" { #include "ffmpeg_codecs.hpp" -#include #include #ifdef WIN32 #define HAVE_FFMPEG_SWSCALE 1 + #include #include #include #else diff --git a/modules/highgui/src/cap_openni.cpp b/modules/highgui/src/cap_openni.cpp index 59e19d14a3..fed59de748 100644 --- a/modules/highgui/src/cap_openni.cpp +++ b/modules/highgui/src/cap_openni.cpp @@ -39,8 +39,8 @@ // //M*/ #include "precomp.hpp" -#include "opencv2/core/core.hpp" -#include "opencv2/imgproc/imgproc.hpp" +#include "opencv2/core.hpp" +#include "opencv2/imgproc.hpp" #ifdef HAVE_OPENNI diff --git a/modules/highgui/src/cap_qtkit.mm b/modules/highgui/src/cap_qtkit.mm index 34d1518dec..d44b7636d7 100644 --- a/modules/highgui/src/cap_qtkit.mm +++ b/modules/highgui/src/cap_qtkit.mm @@ -29,7 +29,7 @@ */ #include "precomp.hpp" -#include "opencv2/imgproc/imgproc.hpp" +#include "opencv2/imgproc.hpp" #include #import diff --git a/modules/highgui/src/grfmt_webp.cpp b/modules/highgui/src/grfmt_webp.cpp index b2722ccea6..39a7a2ab44 100644 --- a/modules/highgui/src/grfmt_webp.cpp +++ b/modules/highgui/src/grfmt_webp.cpp @@ -51,7 +51,7 @@ #include "grfmt_webp.hpp" -#include "opencv2/imgproc/imgproc.hpp" +#include "opencv2/imgproc.hpp" namespace cv { diff --git a/modules/highgui/src/precomp.hpp b/modules/highgui/src/precomp.hpp index 9572e30100..d83401cd65 100644 --- a/modules/highgui/src/precomp.hpp +++ b/modules/highgui/src/precomp.hpp @@ -44,7 +44,7 @@ #include "cvconfig.h" -#include "opencv2/highgui/highgui.hpp" +#include "opencv2/highgui.hpp" #include "opencv2/highgui/highgui_c.h" #include "opencv2/imgproc/imgproc_c.h" #include "opencv2/core/internal.hpp" diff --git a/modules/highgui/src/window.cpp b/modules/highgui/src/window.cpp index b039045356..c89a0a514d 100644 --- a/modules/highgui/src/window.cpp +++ b/modules/highgui/src/window.cpp @@ -41,7 +41,7 @@ #include "precomp.hpp" #include -#include "opencv2/core/opengl_interop.hpp" +#include "opencv2/core/opengl.hpp" // in later times, use this file as a dispatcher to implementations like cvcap.cpp diff --git a/modules/highgui/src/window_w32.cpp b/modules/highgui/src/window_w32.cpp index 094819740d..71445297a7 100644 --- a/modules/highgui/src/window_w32.cpp +++ b/modules/highgui/src/window_w32.cpp @@ -75,7 +75,7 @@ #include #include #include -#include "opencv2/highgui/highgui.hpp" +#include "opencv2/highgui.hpp" #include #endif diff --git a/modules/highgui/test/test_drawing.cpp b/modules/highgui/test/test_drawing.cpp index a23df6b9bd..0769f0ce7f 100644 --- a/modules/highgui/test/test_drawing.cpp +++ b/modules/highgui/test/test_drawing.cpp @@ -41,7 +41,7 @@ //M*/ #include "test_precomp.hpp" -#include "opencv2/highgui/highgui.hpp" +#include "opencv2/highgui.hpp" using namespace std; using namespace cv; diff --git a/modules/highgui/test/test_ffmpeg.cpp b/modules/highgui/test/test_ffmpeg.cpp index 53065462a2..ca22ca0ddb 100644 --- a/modules/highgui/test/test_ffmpeg.cpp +++ b/modules/highgui/test/test_ffmpeg.cpp @@ -41,7 +41,7 @@ //M*/ #include "test_precomp.hpp" -#include "opencv2/highgui/highgui.hpp" +#include "opencv2/highgui.hpp" using namespace cv; diff --git a/modules/highgui/test/test_fourcc.cpp b/modules/highgui/test/test_fourcc.cpp index 4a2757c10e..584b8c5964 100644 --- a/modules/highgui/test/test_fourcc.cpp +++ b/modules/highgui/test/test_fourcc.cpp @@ -41,7 +41,7 @@ //M*/ #include "test_precomp.hpp" -#include "opencv2/highgui/highgui.hpp" +#include "opencv2/highgui.hpp" #undef DEFINE_GUID #define DEFINE_GUID(n, fourcc, a1, a2, a3, a4, a5, a6, a7, a8, a9, a10) fourcc, diff --git a/modules/highgui/test/test_framecount.cpp b/modules/highgui/test/test_framecount.cpp index 80bcfafb73..69ebf5cf83 100644 --- a/modules/highgui/test/test_framecount.cpp +++ b/modules/highgui/test/test_framecount.cpp @@ -41,7 +41,7 @@ //M*/ #include "test_precomp.hpp" -#include "opencv2/highgui/highgui.hpp" +#include "opencv2/highgui.hpp" #include using namespace cv; diff --git a/modules/highgui/test/test_grfmt.cpp b/modules/highgui/test/test_grfmt.cpp index 43198f5af7..57b48a290e 100644 --- a/modules/highgui/test/test_grfmt.cpp +++ b/modules/highgui/test/test_grfmt.cpp @@ -41,7 +41,7 @@ //M*/ #include "test_precomp.hpp" -#include "opencv2/highgui/highgui.hpp" +#include "opencv2/highgui.hpp" using namespace cv; using namespace std; diff --git a/modules/highgui/test/test_gui.cpp b/modules/highgui/test/test_gui.cpp index 285203cb04..9ca0aaf7cb 100644 --- a/modules/highgui/test/test_gui.cpp +++ b/modules/highgui/test/test_gui.cpp @@ -41,7 +41,7 @@ //M*/ #include "test_precomp.hpp" -#include "opencv2/highgui/highgui.hpp" +#include "opencv2/highgui.hpp" #if defined HAVE_GTK || defined HAVE_QT || defined WIN32 || defined _WIN32 || defined HAVE_CARBON || defined HAVE_COCOA diff --git a/modules/highgui/test/test_positioning.cpp b/modules/highgui/test/test_positioning.cpp index 9f022ca9f9..a13aab0f54 100644 --- a/modules/highgui/test/test_positioning.cpp +++ b/modules/highgui/test/test_positioning.cpp @@ -41,7 +41,7 @@ //M*/ #include "test_precomp.hpp" -#include "opencv2/highgui/highgui.hpp" +#include "opencv2/highgui.hpp" #include using namespace cv; diff --git a/modules/highgui/test/test_precomp.hpp b/modules/highgui/test/test_precomp.hpp index 3286c0f59a..ba4241e25f 100644 --- a/modules/highgui/test/test_precomp.hpp +++ b/modules/highgui/test/test_precomp.hpp @@ -13,8 +13,8 @@ # include "cvconfig.h" #endif -#include "opencv2/ts/ts.hpp" -#include "opencv2/imgproc/imgproc.hpp" +#include "opencv2/ts.hpp" +#include "opencv2/imgproc.hpp" #include "opencv2/imgproc/imgproc_c.h" #include diff --git a/modules/highgui/test/test_video_io.cpp b/modules/highgui/test/test_video_io.cpp index b0c2e53ba5..b91acf74ab 100644 --- a/modules/highgui/test/test_video_io.cpp +++ b/modules/highgui/test/test_video_io.cpp @@ -41,7 +41,7 @@ //M*/ #include "test_precomp.hpp" -#include "opencv2/highgui/highgui.hpp" +#include "opencv2/highgui.hpp" using namespace cv; using namespace std; diff --git a/modules/highgui/test/test_video_pos.cpp b/modules/highgui/test/test_video_pos.cpp index ce0df40ff6..a9fa36c250 100644 --- a/modules/highgui/test/test_video_pos.cpp +++ b/modules/highgui/test/test_video_pos.cpp @@ -41,7 +41,7 @@ //M*/ #include "test_precomp.hpp" -#include "opencv2/highgui/highgui.hpp" +#include "opencv2/highgui.hpp" using namespace cv; using namespace std; diff --git a/modules/imgproc/include/opencv2/imgproc/imgproc.hpp b/modules/imgproc/include/opencv2/imgproc.hpp similarity index 99% rename from modules/imgproc/include/opencv2/imgproc/imgproc.hpp rename to modules/imgproc/include/opencv2/imgproc.hpp index 91cf1f974b..542ab0cdca 100644 --- a/modules/imgproc/include/opencv2/imgproc/imgproc.hpp +++ b/modules/imgproc/include/opencv2/imgproc.hpp @@ -43,7 +43,7 @@ #ifndef __OPENCV_IMGPROC_HPP__ #define __OPENCV_IMGPROC_HPP__ -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" #include "opencv2/imgproc/types_c.h" #ifdef __cplusplus diff --git a/modules/imgproc/perf/perf_precomp.hpp b/modules/imgproc/perf/perf_precomp.hpp index 304802491d..19f62712c1 100644 --- a/modules/imgproc/perf/perf_precomp.hpp +++ b/modules/imgproc/perf/perf_precomp.hpp @@ -9,9 +9,9 @@ #ifndef __OPENCV_PERF_PRECOMP_HPP__ #define __OPENCV_PERF_PRECOMP_HPP__ -#include "opencv2/ts/ts.hpp" -#include "opencv2/imgproc/imgproc.hpp" -#include "opencv2/highgui/highgui.hpp" +#include "opencv2/ts.hpp" +#include "opencv2/imgproc.hpp" +#include "opencv2/highgui.hpp" #ifdef GTEST_CREATE_SHARED_LIBRARY #error no modules except ts should have GTEST_CREATE_SHARED_LIBRARY defined diff --git a/modules/imgproc/src/precomp.hpp b/modules/imgproc/src/precomp.hpp index 4d8e1daf48..c3e693c31c 100644 --- a/modules/imgproc/src/precomp.hpp +++ b/modules/imgproc/src/precomp.hpp @@ -47,7 +47,7 @@ #include "cvconfig.h" #endif -#include "opencv2/imgproc/imgproc.hpp" +#include "opencv2/imgproc.hpp" #include "opencv2/imgproc/imgproc_c.h" #include "opencv2/core/internal.hpp" #include diff --git a/modules/imgproc/test/test_precomp.hpp b/modules/imgproc/test/test_precomp.hpp index 4c973c1ae0..9e937b9416 100644 --- a/modules/imgproc/test/test_precomp.hpp +++ b/modules/imgproc/test/test_precomp.hpp @@ -9,10 +9,10 @@ #ifndef __OPENCV_TEST_PRECOMP_HPP__ #define __OPENCV_TEST_PRECOMP_HPP__ -#include "opencv2/ts/ts.hpp" -#include "opencv2/imgproc/imgproc.hpp" +#include "opencv2/ts.hpp" +#include "opencv2/imgproc.hpp" #include "opencv2/imgproc/imgproc_c.h" -#include "opencv2/highgui/highgui.hpp" +#include "opencv2/highgui.hpp" #include "opencv2/highgui/highgui_c.h" #include diff --git a/modules/java/generator/config/core.filelist b/modules/java/generator/config/core.filelist index 1bdc030877..96c377786d 100644 --- a/modules/java/generator/config/core.filelist +++ b/modules/java/generator/config/core.filelist @@ -1,2 +1,2 @@ -include/opencv2/core/core.hpp +include/opencv2/core.hpp ../java/generator/src/cpp/core_manual.hpp diff --git a/modules/java/generator/gen_java.py b/modules/java/generator/gen_java.py index a703fb8491..030f6c897a 100755 --- a/modules/java/generator/gen_java.py +++ b/modules/java/generator/gen_java.py @@ -884,7 +884,7 @@ public class %(jc)s { #define LOG_TAG "org.opencv.%(m)s" #include "common.h" -#include "opencv2/%(m)s/%(m)s.hpp" +#include "opencv2/%(m)s.hpp" using namespace cv; diff --git a/modules/java/generator/src/cpp/Mat.cpp b/modules/java/generator/src/cpp/Mat.cpp index 726dcaf5fb..6b1d10038b 100644 --- a/modules/java/generator/src/cpp/Mat.cpp +++ b/modules/java/generator/src/cpp/Mat.cpp @@ -1,7 +1,7 @@ #define LOG_TAG "org.opencv.core.Mat" #include "common.h" -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" using namespace cv; diff --git a/modules/java/generator/src/cpp/VideoCapture.cpp b/modules/java/generator/src/cpp/VideoCapture.cpp index 5b9266660f..f0e5c233b6 100644 --- a/modules/java/generator/src/cpp/VideoCapture.cpp +++ b/modules/java/generator/src/cpp/VideoCapture.cpp @@ -5,7 +5,7 @@ #ifdef HAVE_OPENCV_HIGHGUI #include "opencv2/highgui/highgui_c.h" -#include "opencv2/highgui/highgui.hpp" +#include "opencv2/highgui.hpp" using namespace cv; diff --git a/modules/java/generator/src/cpp/converters.h b/modules/java/generator/src/cpp/converters.h index bdffe92699..27651bc80d 100644 --- a/modules/java/generator/src/cpp/converters.h +++ b/modules/java/generator/src/cpp/converters.h @@ -1,5 +1,5 @@ #include "opencv2/opencv_modules.hpp" -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" #include "features2d_manual.hpp" void Mat_to_vector_int(cv::Mat& mat, std::vector& v_int); diff --git a/modules/java/generator/src/cpp/core_manual.hpp b/modules/java/generator/src/cpp/core_manual.hpp index a2fc627820..82d460fa53 100644 --- a/modules/java/generator/src/cpp/core_manual.hpp +++ b/modules/java/generator/src/cpp/core_manual.hpp @@ -1,6 +1,6 @@ #pragma once -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" namespace cv { diff --git a/modules/java/generator/src/cpp/features2d_manual.hpp b/modules/java/generator/src/cpp/features2d_manual.hpp index 4c43757ffc..39fcafa2dd 100644 --- a/modules/java/generator/src/cpp/features2d_manual.hpp +++ b/modules/java/generator/src/cpp/features2d_manual.hpp @@ -4,7 +4,7 @@ #include "opencv2/opencv_modules.hpp" #ifdef HAVE_OPENCV_FEATURES2D -#include "opencv2/features2d/features2d.hpp" +#include "opencv2/features2d.hpp" #undef SIMPLEBLOB // to solve conflict with wincrypt.h on windows diff --git a/modules/java/generator/src/cpp/jni_part.cpp b/modules/java/generator/src/cpp/jni_part.cpp index df1bd142ca..8f6eb81618 100644 --- a/modules/java/generator/src/cpp/jni_part.cpp +++ b/modules/java/generator/src/cpp/jni_part.cpp @@ -3,23 +3,23 @@ #include "opencv2/opencv_modules.hpp" #ifdef HAVE_OPENCV_NONFREE -# include "opencv2/nonfree/nonfree.hpp" +# include "opencv2/nonfree.hpp" #endif #ifdef HAVE_OPENCV_FEATURES2D -# include "opencv2/features2d/features2d.hpp" +# include "opencv2/features2d.hpp" #endif #ifdef HAVE_OPENCV_VIDEO -# include "opencv2/video/video.hpp" +# include "opencv2/video.hpp" #endif #ifdef HAVE_OPENCV_ML -# include "opencv2/ml/ml.hpp" +# include "opencv2/ml.hpp" #endif #ifdef HAVE_OPENCV_CONTRIB -# include "opencv2/contrib/contrib.hpp" +# include "opencv2/contrib.hpp" #endif extern "C" { diff --git a/modules/java/generator/src/cpp/utils.cpp b/modules/java/generator/src/cpp/utils.cpp index 9f6b1bfcff..ed964e377e 100644 --- a/modules/java/generator/src/cpp/utils.cpp +++ b/modules/java/generator/src/cpp/utils.cpp @@ -1,8 +1,8 @@ #define LOG_TAG "org.opencv.android.Utils" #include "common.h" -#include "opencv2/core/core.hpp" -#include "opencv2/imgproc/imgproc.hpp" +#include "opencv2/core.hpp" +#include "opencv2/imgproc.hpp" #ifdef __ANDROID__ #include diff --git a/modules/legacy/include/opencv2/legacy/legacy.hpp b/modules/legacy/include/opencv2/legacy.hpp similarity index 99% rename from modules/legacy/include/opencv2/legacy/legacy.hpp rename to modules/legacy/include/opencv2/legacy.hpp index 104aace82b..7b765b0c8f 100644 --- a/modules/legacy/include/opencv2/legacy/legacy.hpp +++ b/modules/legacy/include/opencv2/legacy.hpp @@ -42,11 +42,11 @@ #ifndef __OPENCV_LEGACY_HPP__ #define __OPENCV_LEGACY_HPP__ -#include "opencv2/imgproc/imgproc.hpp" +#include "opencv2/imgproc.hpp" #include "opencv2/imgproc/imgproc_c.h" -#include "opencv2/features2d/features2d.hpp" -#include "opencv2/calib3d/calib3d.hpp" -#include "opencv2/ml/ml.hpp" +#include "opencv2/features2d.hpp" +#include "opencv2/calib3d.hpp" +#include "opencv2/ml.hpp" #ifdef __cplusplus extern "C" { diff --git a/modules/legacy/src/oneway.cpp b/modules/legacy/src/oneway.cpp index f4c0a992b2..eae17a5d47 100644 --- a/modules/legacy/src/oneway.cpp +++ b/modules/legacy/src/oneway.cpp @@ -10,7 +10,7 @@ #include "precomp.hpp" #include "opencv2/opencv_modules.hpp" #ifdef HAVE_OPENCV_HIGHGUI -# include "opencv2/highgui/highgui.hpp" +# include "opencv2/highgui.hpp" #endif #include diff --git a/modules/legacy/src/precomp.hpp b/modules/legacy/src/precomp.hpp index 48b9e4a230..6e40e3ffd0 100644 --- a/modules/legacy/src/precomp.hpp +++ b/modules/legacy/src/precomp.hpp @@ -45,11 +45,10 @@ #include "cvconfig.h" #endif -#include "opencv2/legacy/legacy.hpp" +#include "opencv2/legacy.hpp" #include "opencv2/core/internal.hpp" -#include "opencv2/video/tracking.hpp" -#include "opencv2/video/background_segm.hpp" +#include "opencv2/video.hpp" #include "opencv2/legacy/blobtrack.hpp" #include "opencv2/legacy/compat.hpp" diff --git a/modules/legacy/test/test_precomp.hpp b/modules/legacy/test/test_precomp.hpp index b4ac3f5743..ccfb359fb7 100644 --- a/modules/legacy/test/test_precomp.hpp +++ b/modules/legacy/test/test_precomp.hpp @@ -9,12 +9,12 @@ #ifndef __OPENCV_TEST_PRECOMP_HPP__ #define __OPENCV_TEST_PRECOMP_HPP__ -#include "opencv2/ts/ts.hpp" -#include "opencv2/imgproc/imgproc.hpp" +#include "opencv2/ts.hpp" +#include "opencv2/imgproc.hpp" #include "opencv2/imgproc/imgproc_c.h" -#include "opencv2/highgui/highgui.hpp" +#include "opencv2/highgui.hpp" #include "opencv2/highgui/highgui_c.h" -#include "opencv2/legacy/legacy.hpp" +#include "opencv2/legacy.hpp" #include #endif diff --git a/modules/ml/include/opencv2/ml/ml.hpp b/modules/ml/include/opencv2/ml.hpp similarity index 99% rename from modules/ml/include/opencv2/ml/ml.hpp rename to modules/ml/include/opencv2/ml.hpp index 71dc541a23..9592fe7dfb 100644 --- a/modules/ml/include/opencv2/ml/ml.hpp +++ b/modules/ml/include/opencv2/ml.hpp @@ -41,7 +41,7 @@ #ifndef __OPENCV_ML_HPP__ #define __OPENCV_ML_HPP__ -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" #include #ifdef __cplusplus @@ -327,7 +327,7 @@ struct CV_EXPORTS CvSVMKernel const float* another, float* results, double alpha, double beta ); virtual void calc_intersec( int vcount, int var_count, const float** vecs, - const float* another, float* results ); + const float* another, float* results ); virtual void calc_chi2( int vec_count, int vec_size, const float** vecs, const float* another, float* results ); virtual void calc_linear( int vec_count, int vec_size, const float** vecs, diff --git a/modules/ml/src/precomp.hpp b/modules/ml/src/precomp.hpp index 63002a8e85..112e077911 100644 --- a/modules/ml/src/precomp.hpp +++ b/modules/ml/src/precomp.hpp @@ -45,7 +45,7 @@ #include "cvconfig.h" #endif -#include "opencv2/ml/ml.hpp" +#include "opencv2/ml.hpp" #include "opencv2/core/core_c.h" #include "opencv2/core/internal.hpp" diff --git a/modules/ml/test/test_precomp.hpp b/modules/ml/test/test_precomp.hpp index 3ccf10a4ab..f311d48786 100644 --- a/modules/ml/test/test_precomp.hpp +++ b/modules/ml/test/test_precomp.hpp @@ -9,8 +9,8 @@ #ifndef __OPENCV_TEST_PRECOMP_HPP__ #define __OPENCV_TEST_PRECOMP_HPP__ -#include "opencv2/ts/ts.hpp" -#include "opencv2/ml/ml.hpp" +#include "opencv2/ts.hpp" +#include "opencv2/ml.hpp" #include "opencv2/core/core_c.h" #include #include diff --git a/modules/nonfree/include/opencv2/nonfree/nonfree.hpp b/modules/nonfree/include/opencv2/nonfree.hpp similarity index 100% rename from modules/nonfree/include/opencv2/nonfree/nonfree.hpp rename to modules/nonfree/include/opencv2/nonfree.hpp diff --git a/modules/nonfree/include/opencv2/nonfree/features2d.hpp b/modules/nonfree/include/opencv2/nonfree/features2d.hpp index 0c95829a76..57b9f1e688 100644 --- a/modules/nonfree/include/opencv2/nonfree/features2d.hpp +++ b/modules/nonfree/include/opencv2/nonfree/features2d.hpp @@ -43,7 +43,7 @@ #ifndef __OPENCV_NONFREE_FEATURES_2D_HPP__ #define __OPENCV_NONFREE_FEATURES_2D_HPP__ -#include "opencv2/features2d/features2d.hpp" +#include "opencv2/features2d.hpp" #ifdef __cplusplus diff --git a/modules/nonfree/perf/perf_precomp.hpp b/modules/nonfree/perf/perf_precomp.hpp index 79a368d712..bb03c28b60 100644 --- a/modules/nonfree/perf/perf_precomp.hpp +++ b/modules/nonfree/perf/perf_precomp.hpp @@ -9,9 +9,9 @@ #ifndef __OPENCV_PERF_PRECOMP_HPP__ #define __OPENCV_PERF_PRECOMP_HPP__ -#include "opencv2/ts/ts.hpp" -#include "opencv2/nonfree/nonfree.hpp" -#include "opencv2/highgui/highgui.hpp" +#include "opencv2/ts.hpp" +#include "opencv2/nonfree.hpp" +#include "opencv2/highgui.hpp" #ifdef GTEST_CREATE_SHARED_LIBRARY #error no modules except ts should have GTEST_CREATE_SHARED_LIBRARY defined diff --git a/modules/nonfree/src/precomp.hpp b/modules/nonfree/src/precomp.hpp index 1730b8b10d..ea0aa6bd4a 100644 --- a/modules/nonfree/src/precomp.hpp +++ b/modules/nonfree/src/precomp.hpp @@ -47,8 +47,8 @@ #include "cvconfig.h" #endif -#include "opencv2/nonfree/nonfree.hpp" -#include "opencv2/imgproc/imgproc.hpp" +#include "opencv2/nonfree.hpp" +#include "opencv2/imgproc.hpp" #include "opencv2/core/internal.hpp" #endif diff --git a/modules/nonfree/test/test_features2d.cpp b/modules/nonfree/test/test_features2d.cpp index 34082072ff..5de09f2a09 100644 --- a/modules/nonfree/test/test_features2d.cpp +++ b/modules/nonfree/test/test_features2d.cpp @@ -40,7 +40,7 @@ //M*/ #include "test_precomp.hpp" -#include "opencv2/calib3d/calib3d.hpp" +#include "opencv2/calib3d.hpp" using namespace std; using namespace cv; diff --git a/modules/nonfree/test/test_keypoints.cpp b/modules/nonfree/test/test_keypoints.cpp index 16ae2dcae3..3984f19d89 100644 --- a/modules/nonfree/test/test_keypoints.cpp +++ b/modules/nonfree/test/test_keypoints.cpp @@ -40,7 +40,7 @@ //M*/ #include "test_precomp.hpp" -#include "opencv2/highgui/highgui.hpp" +#include "opencv2/highgui.hpp" using namespace std; using namespace cv; diff --git a/modules/nonfree/test/test_precomp.hpp b/modules/nonfree/test/test_precomp.hpp index 062ab7bb13..daa79c90d3 100644 --- a/modules/nonfree/test/test_precomp.hpp +++ b/modules/nonfree/test/test_precomp.hpp @@ -9,10 +9,10 @@ #ifndef __OPENCV_TEST_PRECOMP_HPP__ #define __OPENCV_TEST_PRECOMP_HPP__ -#include "opencv2/ts/ts.hpp" -#include "opencv2/imgproc/imgproc.hpp" -#include "opencv2/highgui/highgui.hpp" -#include "opencv2/nonfree/nonfree.hpp" +#include "opencv2/ts.hpp" +#include "opencv2/imgproc.hpp" +#include "opencv2/highgui.hpp" +#include "opencv2/nonfree.hpp" #include #endif diff --git a/modules/nonfree/test/test_rotation_and_scale_invariance.cpp b/modules/nonfree/test/test_rotation_and_scale_invariance.cpp index 7ca9e3dd74..9ca0225c2d 100644 --- a/modules/nonfree/test/test_rotation_and_scale_invariance.cpp +++ b/modules/nonfree/test/test_rotation_and_scale_invariance.cpp @@ -40,7 +40,7 @@ //M*/ #include "test_precomp.hpp" -#include "opencv2/highgui/highgui.hpp" +#include "opencv2/highgui.hpp" using namespace std; using namespace cv; diff --git a/modules/objdetect/include/opencv2/objdetect/objdetect.hpp b/modules/objdetect/include/opencv2/objdetect.hpp similarity index 99% rename from modules/objdetect/include/opencv2/objdetect/objdetect.hpp rename to modules/objdetect/include/opencv2/objdetect.hpp index 5492381649..a8c2955e15 100644 --- a/modules/objdetect/include/opencv2/objdetect/objdetect.hpp +++ b/modules/objdetect/include/opencv2/objdetect.hpp @@ -43,7 +43,7 @@ #ifndef __OPENCV_OBJDETECT_HPP__ #define __OPENCV_OBJDETECT_HPP__ -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" #ifdef __cplusplus #include diff --git a/modules/objdetect/perf/perf_cascadeclassifier.cpp b/modules/objdetect/perf/perf_cascadeclassifier.cpp index 27b4226e97..2823302c77 100644 --- a/modules/objdetect/perf/perf_cascadeclassifier.cpp +++ b/modules/objdetect/perf/perf_cascadeclassifier.cpp @@ -1,5 +1,5 @@ #include "perf_precomp.hpp" -#include +#include using namespace std; using namespace cv; diff --git a/modules/objdetect/perf/perf_precomp.hpp b/modules/objdetect/perf/perf_precomp.hpp index d1a7e444cf..29427f7c76 100644 --- a/modules/objdetect/perf/perf_precomp.hpp +++ b/modules/objdetect/perf/perf_precomp.hpp @@ -9,9 +9,9 @@ #ifndef __OPENCV_PERF_PRECOMP_HPP__ #define __OPENCV_PERF_PRECOMP_HPP__ -#include "opencv2/ts/ts.hpp" -#include "opencv2/objdetect/objdetect.hpp" -#include "opencv2/highgui/highgui.hpp" +#include "opencv2/ts.hpp" +#include "opencv2/objdetect.hpp" +#include "opencv2/highgui.hpp" #ifdef GTEST_CREATE_SHARED_LIBRARY #error no modules except ts should have GTEST_CREATE_SHARED_LIBRARY defined diff --git a/modules/objdetect/src/datamatrix.cpp b/modules/objdetect/src/datamatrix.cpp index 374d73ba46..325032c533 100644 --- a/modules/objdetect/src/datamatrix.cpp +++ b/modules/objdetect/src/datamatrix.cpp @@ -483,7 +483,7 @@ endo: ; // end search for this o #endif } -#include +#include namespace cv { diff --git a/modules/objdetect/src/precomp.hpp b/modules/objdetect/src/precomp.hpp index 560ed45a20..2b237a1563 100644 --- a/modules/objdetect/src/precomp.hpp +++ b/modules/objdetect/src/precomp.hpp @@ -47,15 +47,15 @@ #include "cvconfig.h" #endif -#include "opencv2/objdetect/objdetect.hpp" -#include "opencv2/imgproc/imgproc.hpp" +#include "opencv2/objdetect.hpp" +#include "opencv2/imgproc.hpp" #include "opencv2/imgproc/imgproc_c.h" #include "opencv2/core/core_c.h" #include "opencv2/core/internal.hpp" #include "opencv2/opencv_modules.hpp" #ifdef HAVE_OPENCV_HIGHGUI -# include "opencv2/highgui/highgui.hpp" +# include "opencv2/highgui.hpp" #endif #ifdef HAVE_TEGRA_OPTIMIZATION diff --git a/modules/objdetect/test/test_cascadeandhog.cpp b/modules/objdetect/test/test_cascadeandhog.cpp index 41ecb3fdeb..38a9e210d3 100644 --- a/modules/objdetect/test/test_cascadeandhog.cpp +++ b/modules/objdetect/test/test_cascadeandhog.cpp @@ -40,7 +40,7 @@ //M*/ #include "test_precomp.hpp" -#include "opencv2/imgproc/imgproc.hpp" +#include "opencv2/imgproc.hpp" using namespace cv; using namespace std; diff --git a/modules/objdetect/test/test_precomp.hpp b/modules/objdetect/test/test_precomp.hpp index 9100ab04ce..cd0fbe4987 100644 --- a/modules/objdetect/test/test_precomp.hpp +++ b/modules/objdetect/test/test_precomp.hpp @@ -9,9 +9,9 @@ #ifndef __OPENCV_TEST_PRECOMP_HPP__ #define __OPENCV_TEST_PRECOMP_HPP__ -#include "opencv2/ts/ts.hpp" -#include "opencv2/objdetect/objdetect.hpp" -#include "opencv2/imgproc/imgproc.hpp" -#include "opencv2/highgui/highgui.hpp" +#include "opencv2/ts.hpp" +#include "opencv2/objdetect.hpp" +#include "opencv2/imgproc.hpp" +#include "opencv2/highgui.hpp" #endif diff --git a/modules/ocl/include/opencv2/ocl/ocl.hpp b/modules/ocl/include/opencv2/ocl.hpp similarity index 99% rename from modules/ocl/include/opencv2/ocl/ocl.hpp rename to modules/ocl/include/opencv2/ocl.hpp index 9144d13ad6..3cf09dc840 100644 --- a/modules/ocl/include/opencv2/ocl/ocl.hpp +++ b/modules/ocl/include/opencv2/ocl.hpp @@ -47,10 +47,10 @@ #include #include -#include "opencv2/core/core.hpp" -#include "opencv2/imgproc/imgproc.hpp" -#include "opencv2/objdetect/objdetect.hpp" -#include "opencv2/features2d/features2d.hpp" +#include "opencv2/core.hpp" +#include "opencv2/imgproc.hpp" +#include "opencv2/objdetect.hpp" +#include "opencv2/features2d.hpp" namespace cv { diff --git a/modules/ocl/perf/perf_haar.cpp b/modules/ocl/perf/perf_haar.cpp index 525b8fb49b..08c066a311 100644 --- a/modules/ocl/perf/perf_haar.cpp +++ b/modules/ocl/perf/perf_haar.cpp @@ -43,7 +43,6 @@ // //M*/ -#include "opencv2/objdetect/objdetect.hpp" #include "precomp.hpp" #ifdef HAVE_OPENCL diff --git a/modules/ocl/perf/perf_pyrup.cpp b/modules/ocl/perf/perf_pyrup.cpp index a023353ed6..f2400610ad 100644 --- a/modules/ocl/perf/perf_pyrup.cpp +++ b/modules/ocl/perf/perf_pyrup.cpp @@ -43,7 +43,6 @@ // //M*/ -#include "opencv2/core/core.hpp" #include "precomp.hpp" #include #ifdef HAVE_OPENCL diff --git a/modules/ocl/perf/precomp.hpp b/modules/ocl/perf/precomp.hpp index 34eea555f5..ac7bd8be5d 100644 --- a/modules/ocl/perf/precomp.hpp +++ b/modules/ocl/perf/precomp.hpp @@ -62,15 +62,15 @@ #include #include #include "cvconfig.h" -#include "opencv2/core/core.hpp" -#include "opencv2/highgui/highgui.hpp" -//#include "opencv2/calib3d/calib3d.hpp" -#include "opencv2/imgproc/imgproc.hpp" -#include "opencv2/video/video.hpp" -#include "opencv2/ts/ts.hpp" +#include "opencv2/core.hpp" +#include "opencv2/highgui.hpp" +//#include "opencv2/calib3d.hpp" +#include "opencv2/imgproc.hpp" +#include "opencv2/video.hpp" +#include "opencv2/ts.hpp" #include "opencv2/ts/ts_perf.hpp" -#include "opencv2/ocl/ocl.hpp" -//#include "opencv2/nonfree/nonfree.hpp" +#include "opencv2/ocl.hpp" +//#include "opencv2/nonfree.hpp" #include "utility.hpp" #include "interpolation.hpp" diff --git a/modules/ocl/src/precomp.hpp b/modules/ocl/src/precomp.hpp index 73ff267e21..5cbc5364f0 100644 --- a/modules/ocl/src/precomp.hpp +++ b/modules/ocl/src/precomp.hpp @@ -65,14 +65,12 @@ #include #include -#include "opencv2/imgproc/imgproc.hpp" +#include "opencv2/ocl.hpp" #include "opencv2/imgproc/imgproc_c.h" #include "opencv2/core/core_c.h" -#include "opencv2/objdetect/objdetect.hpp" -#include "opencv2/ocl/ocl.hpp" #include "opencv2/core/internal.hpp" -//#include "opencv2/highgui/highgui.hpp" +//#include "opencv2/highgui.hpp" #define __ATI__ diff --git a/modules/ocl/src/surf.cpp b/modules/ocl/src/surf.cpp index a69b0082a7..5d14392286 100644 --- a/modules/ocl/src/surf.cpp +++ b/modules/ocl/src/surf.cpp @@ -45,7 +45,6 @@ #include #include "precomp.hpp" #include "mcwutil.hpp" -//#include "opencv2/highgui/highgui.hpp" using namespace cv; using namespace cv::ocl; diff --git a/modules/ocl/test/precomp.hpp b/modules/ocl/test/precomp.hpp index c630871014..25c95eb77a 100644 --- a/modules/ocl/test/precomp.hpp +++ b/modules/ocl/test/precomp.hpp @@ -62,15 +62,15 @@ #include #include #include "cvconfig.h" -#include "opencv2/core/core.hpp" -#include "opencv2/highgui/highgui.hpp" -//#include "opencv2/calib3d/calib3d.hpp" -#include "opencv2/imgproc/imgproc.hpp" -#include "opencv2/video/video.hpp" -#include "opencv2/ts/ts.hpp" +#include "opencv2/core.hpp" +#include "opencv2/highgui.hpp" +//#include "opencv2/calib3d.hpp" +#include "opencv2/imgproc.hpp" +#include "opencv2/video.hpp" +#include "opencv2/ts.hpp" #include "opencv2/ts/ts_perf.hpp" -#include "opencv2/ocl/ocl.hpp" -//#include "opencv2/nonfree/nonfree.hpp" +#include "opencv2/ocl.hpp" +//#include "opencv2/nonfree.hpp" #include "utility.hpp" #include "interpolation.hpp" diff --git a/modules/ocl/test/test_haar.cpp b/modules/ocl/test/test_haar.cpp index 9bff324662..6d2a912c24 100644 --- a/modules/ocl/test/test_haar.cpp +++ b/modules/ocl/test/test_haar.cpp @@ -43,7 +43,7 @@ // //M*/ -#include "opencv2/objdetect/objdetect.hpp" +#include "opencv2/objdetect.hpp" #include "precomp.hpp" #ifdef HAVE_OPENCL diff --git a/modules/ocl/test/test_hog.cpp b/modules/ocl/test/test_hog.cpp index 02cfe65b8a..9c27c88032 100644 --- a/modules/ocl/test/test_hog.cpp +++ b/modules/ocl/test/test_hog.cpp @@ -44,7 +44,7 @@ //M*/ #include "precomp.hpp" -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" using namespace std; #ifdef HAVE_OPENCL diff --git a/modules/ocl/test/test_pyrup.cpp b/modules/ocl/test/test_pyrup.cpp index 9889b92ac0..2e0cb92cce 100644 --- a/modules/ocl/test/test_pyrup.cpp +++ b/modules/ocl/test/test_pyrup.cpp @@ -45,7 +45,6 @@ //M*/ #include "precomp.hpp" -#include "opencv2/core/core.hpp" #ifdef HAVE_OPENCL diff --git a/modules/photo/include/opencv2/photo/photo.hpp b/modules/photo/include/opencv2/photo.hpp similarity index 98% rename from modules/photo/include/opencv2/photo/photo.hpp rename to modules/photo/include/opencv2/photo.hpp index 66973772e5..07e7e098a9 100644 --- a/modules/photo/include/opencv2/photo/photo.hpp +++ b/modules/photo/include/opencv2/photo.hpp @@ -43,8 +43,8 @@ #ifndef __OPENCV_PHOTO_HPP__ #define __OPENCV_PHOTO_HPP__ -#include "opencv2/core/core.hpp" -#include "opencv2/imgproc/imgproc.hpp" +#include "opencv2/core.hpp" +#include "opencv2/imgproc.hpp" #include "opencv2/photo/photo_c.h" diff --git a/modules/photo/perf/perf_precomp.hpp b/modules/photo/perf/perf_precomp.hpp index 1172333334..1fd0c81093 100644 --- a/modules/photo/perf/perf_precomp.hpp +++ b/modules/photo/perf/perf_precomp.hpp @@ -9,9 +9,9 @@ #ifndef __OPENCV_PERF_PRECOMP_HPP__ #define __OPENCV_PERF_PRECOMP_HPP__ -#include "opencv2/ts/ts.hpp" -#include "opencv2/photo/photo.hpp" -#include "opencv2/highgui/highgui.hpp" +#include "opencv2/ts.hpp" +#include "opencv2/photo.hpp" +#include "opencv2/highgui.hpp" #ifdef GTEST_CREATE_SHARED_LIBRARY #error no modules except ts should have GTEST_CREATE_SHARED_LIBRARY defined diff --git a/modules/photo/src/denoising.cpp b/modules/photo/src/denoising.cpp index df7bcc2acb..299390f154 100644 --- a/modules/photo/src/denoising.cpp +++ b/modules/photo/src/denoising.cpp @@ -40,8 +40,8 @@ //M*/ #include "precomp.hpp" -#include "opencv2/photo/photo.hpp" -#include "opencv2/imgproc/imgproc.hpp" +#include "opencv2/photo.hpp" +#include "opencv2/imgproc.hpp" #include "fast_nlmeans_denoising_invoker.hpp" #include "fast_nlmeans_multi_denoising_invoker.hpp" diff --git a/modules/photo/src/fast_nlmeans_denoising_invoker.hpp b/modules/photo/src/fast_nlmeans_denoising_invoker.hpp index c00f9abf8d..c2e240b55f 100644 --- a/modules/photo/src/fast_nlmeans_denoising_invoker.hpp +++ b/modules/photo/src/fast_nlmeans_denoising_invoker.hpp @@ -43,9 +43,9 @@ #define __OPENCV_FAST_NLMEANS_DENOISING_INVOKER_HPP__ #include "precomp.hpp" -#include +#include #include -#include +#include #include #include "fast_nlmeans_denoising_invoker_commons.hpp" diff --git a/modules/photo/src/fast_nlmeans_denoising_invoker_commons.hpp b/modules/photo/src/fast_nlmeans_denoising_invoker_commons.hpp index 7dceec270b..fd2b835e32 100644 --- a/modules/photo/src/fast_nlmeans_denoising_invoker_commons.hpp +++ b/modules/photo/src/fast_nlmeans_denoising_invoker_commons.hpp @@ -42,9 +42,9 @@ #ifndef __OPENCV_FAST_NLMEANS_DENOISING_INVOKER_COMMONS_HPP__ #define __OPENCV_FAST_NLMEANS_DENOISING_INVOKER_COMMONS_HPP__ -#include +#include #include -#include +#include using namespace cv; diff --git a/modules/photo/src/fast_nlmeans_multi_denoising_invoker.hpp b/modules/photo/src/fast_nlmeans_multi_denoising_invoker.hpp index 73e0171c6a..037c128a12 100644 --- a/modules/photo/src/fast_nlmeans_multi_denoising_invoker.hpp +++ b/modules/photo/src/fast_nlmeans_multi_denoising_invoker.hpp @@ -43,9 +43,9 @@ #define __OPENCV_FAST_NLMEANS_MULTI_DENOISING_INVOKER_HPP__ #include "precomp.hpp" -#include +#include #include -#include +#include #include #include "fast_nlmeans_denoising_invoker_commons.hpp" diff --git a/modules/photo/src/precomp.hpp b/modules/photo/src/precomp.hpp index 3185a18b86..d397dedf4d 100644 --- a/modules/photo/src/precomp.hpp +++ b/modules/photo/src/precomp.hpp @@ -47,7 +47,7 @@ #include "cvconfig.h" #endif -#include "opencv2/photo/photo.hpp" +#include "opencv2/photo.hpp" #ifdef HAVE_TEGRA_OPTIMIZATION #include "opencv2/photo/photo_tegra.hpp" diff --git a/modules/photo/test/test_denoising.cpp b/modules/photo/test/test_denoising.cpp index 55e876c635..57248c7728 100644 --- a/modules/photo/test/test_denoising.cpp +++ b/modules/photo/test/test_denoising.cpp @@ -41,7 +41,7 @@ //M*/ #include "test_precomp.hpp" -#include "opencv2/photo/photo.hpp" +#include "opencv2/photo.hpp" #include using namespace cv; diff --git a/modules/photo/test/test_precomp.hpp b/modules/photo/test/test_precomp.hpp index d1f3dcab22..278abb496f 100644 --- a/modules/photo/test/test_precomp.hpp +++ b/modules/photo/test/test_precomp.hpp @@ -9,9 +9,9 @@ #ifndef __OPENCV_TEST_PRECOMP_HPP__ #define __OPENCV_TEST_PRECOMP_HPP__ -#include "opencv2/ts/ts.hpp" -#include "opencv2/photo/photo.hpp" -#include "opencv2/highgui/highgui.hpp" +#include "opencv2/ts.hpp" +#include "opencv2/photo.hpp" +#include "opencv2/highgui.hpp" #include #endif diff --git a/modules/python/CMakeLists.txt b/modules/python/CMakeLists.txt index d36b6d8508..d39e91921d 100644 --- a/modules/python/CMakeLists.txt +++ b/modules/python/CMakeLists.txt @@ -23,23 +23,23 @@ ocv_module_include_directories( set(opencv_hdrs - "${OPENCV_MODULE_opencv_core_LOCATION}/include/opencv2/core/core.hpp" + "${OPENCV_MODULE_opencv_core_LOCATION}/include/opencv2/core.hpp" "${OPENCV_MODULE_opencv_flann_LOCATION}/include/opencv2/flann/miniflann.hpp" - "${OPENCV_MODULE_opencv_imgproc_LOCATION}/include/opencv2/imgproc/imgproc.hpp" + "${OPENCV_MODULE_opencv_imgproc_LOCATION}/include/opencv2/imgproc.hpp" "${OPENCV_MODULE_opencv_video_LOCATION}/include/opencv2/video/background_segm.hpp" "${OPENCV_MODULE_opencv_video_LOCATION}/include/opencv2/video/tracking.hpp" - "${OPENCV_MODULE_opencv_photo_LOCATION}/include/opencv2/photo/photo.hpp" - "${OPENCV_MODULE_opencv_highgui_LOCATION}/include/opencv2/highgui/highgui.hpp" - "${OPENCV_MODULE_opencv_ml_LOCATION}/include/opencv2/ml/ml.hpp" - "${OPENCV_MODULE_opencv_features2d_LOCATION}/include/opencv2/features2d/features2d.hpp" - "${OPENCV_MODULE_opencv_calib3d_LOCATION}/include/opencv2/calib3d/calib3d.hpp" - "${OPENCV_MODULE_opencv_objdetect_LOCATION}/include/opencv2/objdetect/objdetect.hpp" - "${OPENCV_MODULE_opencv_softcascade_LOCATION}/include/opencv2/softcascade/softcascade.hpp" - "${OPENCV_MODULE_opencv_contrib_LOCATION}/include/opencv2/contrib/contrib.hpp") + "${OPENCV_MODULE_opencv_photo_LOCATION}/include/opencv2/photo.hpp" + "${OPENCV_MODULE_opencv_highgui_LOCATION}/include/opencv2/highgui.hpp" + "${OPENCV_MODULE_opencv_ml_LOCATION}/include/opencv2/ml.hpp" + "${OPENCV_MODULE_opencv_features2d_LOCATION}/include/opencv2/features2d.hpp" + "${OPENCV_MODULE_opencv_calib3d_LOCATION}/include/opencv2/calib3d.hpp" + "${OPENCV_MODULE_opencv_objdetect_LOCATION}/include/opencv2/objdetect.hpp" + "${OPENCV_MODULE_opencv_softcascade_LOCATION}/include/opencv2/softcascade.hpp" + "${OPENCV_MODULE_opencv_contrib_LOCATION}/include/opencv2/contrib.hpp") if(HAVE_opencv_nonfree) list(APPEND opencv_hdrs "${OPENCV_MODULE_opencv_nonfree_LOCATION}/include/opencv2/nonfree/features2d.hpp" - "${OPENCV_MODULE_opencv_nonfree_LOCATION}/include/opencv2/nonfree/nonfree.hpp") + "${OPENCV_MODULE_opencv_nonfree_LOCATION}/include/opencv2/nonfree.hpp") endif() set(cv2_generated_hdrs diff --git a/modules/python/src2/cv2.cpp b/modules/python/src2/cv2.cpp index 29a9b717e2..bbdd5abbe7 100644 --- a/modules/python/src2/cv2.cpp +++ b/modules/python/src2/cv2.cpp @@ -8,24 +8,24 @@ #include "numpy/ndarrayobject.h" -#include "opencv2/core/core.hpp" -#include "opencv2/contrib/contrib.hpp" +#include "opencv2/core.hpp" +#include "opencv2/contrib.hpp" #include "opencv2/flann/miniflann.hpp" -#include "opencv2/imgproc/imgproc.hpp" -#include "opencv2/calib3d/calib3d.hpp" -#include "opencv2/ml/ml.hpp" -#include "opencv2/features2d/features2d.hpp" -#include "opencv2/objdetect/objdetect.hpp" -#include "opencv2/softcascade/softcascade.hpp" +#include "opencv2/imgproc.hpp" +#include "opencv2/calib3d.hpp" +#include "opencv2/ml.hpp" +#include "opencv2/features2d.hpp" +#include "opencv2/objdetect.hpp" +#include "opencv2/softcascade.hpp" #include "opencv2/video/tracking.hpp" #include "opencv2/video/background_segm.hpp" -#include "opencv2/photo/photo.hpp" -#include "opencv2/highgui/highgui.hpp" +#include "opencv2/photo.hpp" +#include "opencv2/highgui.hpp" #include "opencv2/opencv_modules.hpp" #ifdef HAVE_OPENCV_NONFREE -# include "opencv2/nonfree/nonfree.hpp" +# include "opencv2/nonfree.hpp" #endif using cv::flann::IndexParams; diff --git a/modules/python/src2/cv2.cv.hpp b/modules/python/src2/cv2.cv.hpp index 06c37cbb3f..f7a6f73777 100644 --- a/modules/python/src2/cv2.cv.hpp +++ b/modules/python/src2/cv2.cv.hpp @@ -1,4 +1,4 @@ -#include "opencv2/legacy/legacy.hpp" +#include "opencv2/legacy.hpp" #include "opencv2/legacy/compat.hpp" #define OLD_MODULESTR "cv2.cv" @@ -3882,23 +3882,23 @@ static PyMethodDef old_methods[] = { #include "opencv2/opencv_modules.hpp" #ifdef HAVE_OPENCV_NONFREE -# include "opencv2/nonfree/nonfree.hpp" +# include "opencv2/nonfree.hpp" #endif #ifdef HAVE_OPENCV_FEATURES2D -# include "opencv2/features2d/features2d.hpp" +# include "opencv2/features2d.hpp" #endif #ifdef HAVE_OPENCV_VIDEO -# include "opencv2/video/video.hpp" +# include "opencv2/video.hpp" #endif #ifdef HAVE_OPENCV_ML -# include "opencv2/ml/ml.hpp" +# include "opencv2/ml.hpp" #endif #ifdef HAVE_OPENCV_CONTRIB -# include "opencv2/contrib/contrib.hpp" +# include "opencv2/contrib.hpp" #endif static PyObject* init_cv() diff --git a/modules/python/src2/hdr_parser.py b/modules/python/src2/hdr_parser.py index 4c81b04ff7..77597ab043 100755 --- a/modules/python/src2/hdr_parser.py +++ b/modules/python/src2/hdr_parser.py @@ -4,17 +4,17 @@ import os, sys, re, string # the list only for debugging. The real list, used in the real OpenCV build, is specified in CMakeLists.txt opencv_hdr_list = [ -"../../core/include/opencv2/core/core.hpp", +"../../core/include/opencv2/core.hpp", "../../flann/include/opencv2/flann/miniflann.hpp", -"../../ml/include/opencv2/ml/ml.hpp", -"../../imgproc/include/opencv2/imgproc/imgproc.hpp", -"../../calib3d/include/opencv2/calib3d/calib3d.hpp", -"../../features2d/include/opencv2/features2d/features2d.hpp", +"../../ml/include/opencv2/ml.hpp", +"../../imgproc/include/opencv2/imgproc.hpp", +"../../calib3d/include/opencv2/calib3d.hpp", +"../../features2d/include/opencv2/features2d.hpp", "../../video/include/opencv2/video/tracking.hpp", "../../video/include/opencv2/video/background_segm.hpp", -"../../objdetect/include/opencv2/objdetect/objdetect.hpp", -"../../contrib/include/opencv2/contrib/contrib.hpp", -"../../highgui/include/opencv2/highgui/highgui.hpp" +"../../objdetect/include/opencv2/objdetect.hpp", +"../../contrib/include/opencv2/contrib.hpp", +"../../highgui/include/opencv2/highgui.hpp" ] """ diff --git a/modules/softcascade/include/opencv2/softcascade/softcascade.hpp b/modules/softcascade/include/opencv2/softcascade.hpp similarity index 99% rename from modules/softcascade/include/opencv2/softcascade/softcascade.hpp rename to modules/softcascade/include/opencv2/softcascade.hpp index 945b61f01a..e0dbdf4500 100644 --- a/modules/softcascade/include/opencv2/softcascade/softcascade.hpp +++ b/modules/softcascade/include/opencv2/softcascade.hpp @@ -43,7 +43,7 @@ #ifndef __OPENCV_SOFTCASCADE_HPP__ #define __OPENCV_SOFTCASCADE_HPP__ -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" namespace cv { namespace softcascade { diff --git a/modules/softcascade/perf/perf_precomp.hpp b/modules/softcascade/perf/perf_precomp.hpp index b761c88c64..667e30a293 100644 --- a/modules/softcascade/perf/perf_precomp.hpp +++ b/modules/softcascade/perf/perf_precomp.hpp @@ -51,9 +51,9 @@ #ifndef __OPENCV_PERF_PRECOMP_HPP__ #define __OPENCV_PERF_PRECOMP_HPP__ -# include "opencv2/ts/ts.hpp" -# include "opencv2/softcascade/softcascade.hpp" -# include "opencv2/highgui/highgui.hpp" +# include "opencv2/ts.hpp" +# include "opencv2/softcascade.hpp" +# include "opencv2/highgui.hpp" #ifdef GTEST_CREATE_SHARED_LIBRARY # error no modules except ts should have GTEST_CREATE_SHARED_LIBRARY defined diff --git a/modules/softcascade/perf/perf_softcascade.cpp b/modules/softcascade/perf/perf_softcascade.cpp index e694697f34..2e9d003103 100644 --- a/modules/softcascade/perf/perf_softcascade.cpp +++ b/modules/softcascade/perf/perf_softcascade.cpp @@ -1,5 +1,5 @@ #include "perf_precomp.hpp" -#include +#include using cv::Rect; using std::tr1::get; diff --git a/modules/softcascade/src/precomp.hpp b/modules/softcascade/src/precomp.hpp index a4eeb59d93..e72b77d409 100644 --- a/modules/softcascade/src/precomp.hpp +++ b/modules/softcascade/src/precomp.hpp @@ -47,12 +47,12 @@ #include "cvconfig.h" #endif -#include "opencv2/softcascade/softcascade.hpp" -#include "opencv2/imgproc/imgproc.hpp" +#include "opencv2/softcascade.hpp" +#include "opencv2/imgproc.hpp" #include "opencv2/imgproc/imgproc_c.h" #include "opencv2/core/core_c.h" #include "opencv2/core/internal.hpp" -#include "opencv2/ml/ml.hpp" +#include "opencv2/ml.hpp" namespace cv { namespace softcascade { namespace internal { diff --git a/modules/softcascade/test/test_precomp.hpp b/modules/softcascade/test/test_precomp.hpp index 6abcbeada9..03d049b94a 100644 --- a/modules/softcascade/test/test_precomp.hpp +++ b/modules/softcascade/test/test_precomp.hpp @@ -51,9 +51,9 @@ #ifndef __OPENCV_TEST_PRECOMP_HPP__ #define __OPENCV_TEST_PRECOMP_HPP__ -# include "opencv2/ts/ts.hpp" -# include "opencv2/softcascade/softcascade.hpp" -# include "opencv2/imgproc/imgproc.hpp" -# include "opencv2/highgui/highgui.hpp" +# include "opencv2/ts.hpp" +# include "opencv2/softcascade.hpp" +# include "opencv2/imgproc.hpp" +# include "opencv2/highgui.hpp" #endif diff --git a/modules/stitching/include/opencv2/stitching/stitcher.hpp b/modules/stitching/include/opencv2/stitching.hpp similarity index 98% rename from modules/stitching/include/opencv2/stitching/stitcher.hpp rename to modules/stitching/include/opencv2/stitching.hpp index e274deb173..3ccd2878a9 100644 --- a/modules/stitching/include/opencv2/stitching/stitcher.hpp +++ b/modules/stitching/include/opencv2/stitching.hpp @@ -43,8 +43,8 @@ #ifndef __OPENCV_STITCHING_STITCHER_HPP__ #define __OPENCV_STITCHING_STITCHER_HPP__ -#include "opencv2/core/core.hpp" -#include "opencv2/features2d/features2d.hpp" +#include "opencv2/core.hpp" +#include "opencv2/features2d.hpp" #include "opencv2/stitching/warpers.hpp" #include "opencv2/stitching/detail/matchers.hpp" #include "opencv2/stitching/detail/motion_estimators.hpp" diff --git a/modules/stitching/include/opencv2/stitching/detail/autocalib.hpp b/modules/stitching/include/opencv2/stitching/detail/autocalib.hpp index feb5349470..519ed804d8 100644 --- a/modules/stitching/include/opencv2/stitching/detail/autocalib.hpp +++ b/modules/stitching/include/opencv2/stitching/detail/autocalib.hpp @@ -43,7 +43,7 @@ #ifndef __OPENCV_STITCHING_AUTOCALIB_HPP__ #define __OPENCV_STITCHING_AUTOCALIB_HPP__ -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" #include "matchers.hpp" namespace cv { diff --git a/modules/stitching/include/opencv2/stitching/detail/blenders.hpp b/modules/stitching/include/opencv2/stitching/detail/blenders.hpp index bd93a717c3..8d47d3225c 100644 --- a/modules/stitching/include/opencv2/stitching/detail/blenders.hpp +++ b/modules/stitching/include/opencv2/stitching/detail/blenders.hpp @@ -43,7 +43,7 @@ #ifndef __OPENCV_STITCHING_BLENDERS_HPP__ #define __OPENCV_STITCHING_BLENDERS_HPP__ -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" namespace cv { namespace detail { diff --git a/modules/stitching/include/opencv2/stitching/detail/camera.hpp b/modules/stitching/include/opencv2/stitching/detail/camera.hpp index a74abcbacf..00ae4eb918 100644 --- a/modules/stitching/include/opencv2/stitching/detail/camera.hpp +++ b/modules/stitching/include/opencv2/stitching/detail/camera.hpp @@ -43,7 +43,7 @@ #ifndef __OPENCV_STITCHING_CAMERA_HPP__ #define __OPENCV_STITCHING_CAMERA_HPP__ -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" namespace cv { namespace detail { diff --git a/modules/stitching/include/opencv2/stitching/detail/exposure_compensate.hpp b/modules/stitching/include/opencv2/stitching/detail/exposure_compensate.hpp index 49676fe9eb..f39785f57c 100644 --- a/modules/stitching/include/opencv2/stitching/detail/exposure_compensate.hpp +++ b/modules/stitching/include/opencv2/stitching/detail/exposure_compensate.hpp @@ -43,7 +43,7 @@ #ifndef __OPENCV_STITCHING_EXPOSURE_COMPENSATE_HPP__ #define __OPENCV_STITCHING_EXPOSURE_COMPENSATE_HPP__ -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" namespace cv { namespace detail { diff --git a/modules/stitching/include/opencv2/stitching/detail/matchers.hpp b/modules/stitching/include/opencv2/stitching/detail/matchers.hpp index f9a53ef432..d6e3b78b1f 100644 --- a/modules/stitching/include/opencv2/stitching/detail/matchers.hpp +++ b/modules/stitching/include/opencv2/stitching/detail/matchers.hpp @@ -43,12 +43,12 @@ #ifndef __OPENCV_STITCHING_MATCHERS_HPP__ #define __OPENCV_STITCHING_MATCHERS_HPP__ -#include "opencv2/core/core.hpp" -#include "opencv2/features2d/features2d.hpp" +#include "opencv2/core.hpp" +#include "opencv2/features2d.hpp" #include "opencv2/opencv_modules.hpp" #ifdef HAVE_OPENCV_GPU -#include "opencv2/gpu/gpu.hpp" +#include "opencv2/gpu.hpp" #endif namespace cv { diff --git a/modules/stitching/include/opencv2/stitching/detail/motion_estimators.hpp b/modules/stitching/include/opencv2/stitching/detail/motion_estimators.hpp index 9ae1102135..0d08b09fc1 100644 --- a/modules/stitching/include/opencv2/stitching/detail/motion_estimators.hpp +++ b/modules/stitching/include/opencv2/stitching/detail/motion_estimators.hpp @@ -43,7 +43,7 @@ #ifndef __OPENCV_STITCHING_MOTION_ESTIMATORS_HPP__ #define __OPENCV_STITCHING_MOTION_ESTIMATORS_HPP__ -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" #include "matchers.hpp" #include "util.hpp" #include "camera.hpp" diff --git a/modules/stitching/include/opencv2/stitching/detail/seam_finders.hpp b/modules/stitching/include/opencv2/stitching/detail/seam_finders.hpp index 09a1a106fd..0587d5ac8a 100644 --- a/modules/stitching/include/opencv2/stitching/detail/seam_finders.hpp +++ b/modules/stitching/include/opencv2/stitching/detail/seam_finders.hpp @@ -44,7 +44,7 @@ #define __OPENCV_STITCHING_SEAM_FINDERS_HPP__ #include -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" #include "opencv2/opencv_modules.hpp" namespace cv { diff --git a/modules/stitching/include/opencv2/stitching/detail/util.hpp b/modules/stitching/include/opencv2/stitching/detail/util.hpp index a8ba81617f..5c00fa343a 100644 --- a/modules/stitching/include/opencv2/stitching/detail/util.hpp +++ b/modules/stitching/include/opencv2/stitching/detail/util.hpp @@ -44,7 +44,7 @@ #define __OPENCV_STITCHING_UTIL_HPP__ #include -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" #define ENABLE_LOG 0 diff --git a/modules/stitching/include/opencv2/stitching/detail/util_inl.hpp b/modules/stitching/include/opencv2/stitching/detail/util_inl.hpp index ab5d94b483..3ff6c9d8b5 100644 --- a/modules/stitching/include/opencv2/stitching/detail/util_inl.hpp +++ b/modules/stitching/include/opencv2/stitching/detail/util_inl.hpp @@ -44,7 +44,7 @@ #define __OPENCV_STITCHING_UTIL_INL_HPP__ #include -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" #include "util.hpp" // Make your IDE see declarations namespace cv { diff --git a/modules/stitching/include/opencv2/stitching/detail/warpers.hpp b/modules/stitching/include/opencv2/stitching/detail/warpers.hpp index 3627d4293f..5a6393a69b 100644 --- a/modules/stitching/include/opencv2/stitching/detail/warpers.hpp +++ b/modules/stitching/include/opencv2/stitching/detail/warpers.hpp @@ -43,11 +43,11 @@ #ifndef __OPENCV_STITCHING_WARPERS_HPP__ #define __OPENCV_STITCHING_WARPERS_HPP__ -#include "opencv2/core/core.hpp" -#include "opencv2/imgproc/imgproc.hpp" +#include "opencv2/core.hpp" +#include "opencv2/imgproc.hpp" #include "opencv2/opencv_modules.hpp" #ifdef HAVE_OPENCV_GPU -# include "opencv2/gpu/gpu.hpp" +# include "opencv2/gpu.hpp" #endif namespace cv { diff --git a/modules/stitching/include/opencv2/stitching/detail/warpers_inl.hpp b/modules/stitching/include/opencv2/stitching/detail/warpers_inl.hpp index b1121232d8..c5f79f1a43 100644 --- a/modules/stitching/include/opencv2/stitching/detail/warpers_inl.hpp +++ b/modules/stitching/include/opencv2/stitching/detail/warpers_inl.hpp @@ -43,7 +43,7 @@ #ifndef __OPENCV_STITCHING_WARPERS_INL_HPP__ #define __OPENCV_STITCHING_WARPERS_INL_HPP__ -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" #include "warpers.hpp" // Make your IDE see declarations namespace cv { diff --git a/modules/stitching/perf/perf_precomp.hpp b/modules/stitching/perf/perf_precomp.hpp index 559891fe33..ba34acb761 100644 --- a/modules/stitching/perf/perf_precomp.hpp +++ b/modules/stitching/perf/perf_precomp.hpp @@ -9,9 +9,8 @@ #ifndef __OPENCV_PERF_PRECOMP_HPP__ #define __OPENCV_PERF_PRECOMP_HPP__ -#include "opencv2/ts/ts.hpp" - -#include "opencv2/stitching/stitcher.hpp" +#include "opencv2/ts.hpp" +#include "opencv2/stitching.hpp" #ifdef GTEST_CREATE_SHARED_LIBRARY #error no modules except ts should have GTEST_CREATE_SHARED_LIBRARY defined diff --git a/modules/stitching/perf/perf_stich.cpp b/modules/stitching/perf/perf_stich.cpp index fff134ce1e..5afe217b02 100644 --- a/modules/stitching/perf/perf_stich.cpp +++ b/modules/stitching/perf/perf_stich.cpp @@ -1,7 +1,7 @@ #include "perf_precomp.hpp" -#include "opencv2/highgui/highgui.hpp" +#include "opencv2/highgui.hpp" #include "opencv2/core/internal.hpp" -#include "opencv2/flann/flann.hpp" +#include "opencv2/flann.hpp" #include "opencv2/opencv_modules.hpp" using namespace std; diff --git a/modules/stitching/src/matchers.cpp b/modules/stitching/src/matchers.cpp index 9584d4811f..ebc0709519 100644 --- a/modules/stitching/src/matchers.cpp +++ b/modules/stitching/src/matchers.cpp @@ -50,7 +50,7 @@ using namespace cv::gpu; #endif #ifdef HAVE_OPENCV_NONFREE -#include "opencv2/nonfree/nonfree.hpp" +#include "opencv2/nonfree.hpp" static bool makeUseOfNonfree = initModule_nonfree(); #endif diff --git a/modules/stitching/src/precomp.hpp b/modules/stitching/src/precomp.hpp index 80eb1868e1..7d75786d7c 100644 --- a/modules/stitching/src/precomp.hpp +++ b/modules/stitching/src/precomp.hpp @@ -55,9 +55,9 @@ #include #include #include -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" #include "opencv2/core/internal.hpp" -#include "opencv2/stitching/stitcher.hpp" +#include "opencv2/stitching.hpp" #include "opencv2/stitching/detail/autocalib.hpp" #include "opencv2/stitching/detail/blenders.hpp" #include "opencv2/stitching/detail/camera.hpp" @@ -67,11 +67,11 @@ #include "opencv2/stitching/detail/seam_finders.hpp" #include "opencv2/stitching/detail/util.hpp" #include "opencv2/stitching/detail/warpers.hpp" -#include "opencv2/imgproc/imgproc.hpp" -#include "opencv2/features2d/features2d.hpp" -#include "opencv2/calib3d/calib3d.hpp" +#include "opencv2/imgproc.hpp" +#include "opencv2/features2d.hpp" +#include "opencv2/calib3d.hpp" #ifdef HAVE_OPENCV_GPU -# include "opencv2/gpu/gpu.hpp" +# include "opencv2/gpu.hpp" #endif #include "../../imgproc/src/gcgraph.hpp" diff --git a/modules/stitching/test/test_precomp.hpp b/modules/stitching/test/test_precomp.hpp index 5509d1c86e..60d6b3f057 100644 --- a/modules/stitching/test/test_precomp.hpp +++ b/modules/stitching/test/test_precomp.hpp @@ -11,9 +11,9 @@ #include #include -#include -#include -#include +#include +#include +#include #include #include diff --git a/modules/ts/include/opencv2/ts/ts.hpp b/modules/ts/include/opencv2/ts.hpp similarity index 99% rename from modules/ts/include/opencv2/ts/ts.hpp rename to modules/ts/include/opencv2/ts.hpp index a10251d414..61e75be381 100644 --- a/modules/ts/include/opencv2/ts/ts.hpp +++ b/modules/ts/include/opencv2/ts.hpp @@ -35,7 +35,7 @@ # define GTEST_USES_POSIX_RE 0 #endif -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" namespace cvtest { @@ -578,4 +578,4 @@ int main(int argc, char **argv) \ #endif -#include "ts_perf.hpp" +#include "opencv2/ts/ts_perf.hpp" diff --git a/modules/ts/include/opencv2/ts/ts_perf.hpp b/modules/ts/include/opencv2/ts/ts_perf.hpp index 0af6718085..cd8209fc67 100644 --- a/modules/ts/include/opencv2/ts/ts_perf.hpp +++ b/modules/ts/include/opencv2/ts/ts_perf.hpp @@ -1,8 +1,8 @@ #ifndef __OPENCV_TS_PERF_HPP__ #define __OPENCV_TS_PERF_HPP__ -#include "opencv2/core/core.hpp" -#include "opencv2/features2d/features2d.hpp" +#include "opencv2/core.hpp" +#include "opencv2/features2d.hpp" #include "ts_gtest.h" #ifdef HAVE_TBB diff --git a/modules/ts/src/precomp.hpp b/modules/ts/src/precomp.hpp index 10acd7ad8f..0bc076376c 100644 --- a/modules/ts/src/precomp.hpp +++ b/modules/ts/src/precomp.hpp @@ -1,5 +1,5 @@ #include "opencv2/core/core_c.h" -#include "opencv2/ts/ts.hpp" +#include "opencv2/ts.hpp" #ifdef GTEST_LINKED_AS_SHARED_LIBRARY #error ts module should not have GTEST_LINKED_AS_SHARED_LIBRARY defined diff --git a/modules/video/doc/motion_analysis_and_object_tracking.rst b/modules/video/doc/motion_analysis_and_object_tracking.rst index 39ff3df686..53922a56ce 100644 --- a/modules/video/doc/motion_analysis_and_object_tracking.rst +++ b/modules/video/doc/motion_analysis_and_object_tracking.rst @@ -179,8 +179,7 @@ The function estimates the optimum transformation (``warpMatrix``) with respect ..math:: -\texttt{warpMatrix} = - \texttt{warpMatrix} = \arg\max_{W} \texttt{ECC}(\texttt{templateImage}(x,y),\texttt{inputImage}(x',y')) + \texttt{warpMatrix} = \texttt{warpMatrix} = \arg\max_{W} \texttt{ECC}(\texttt{templateImage}(x,y),\texttt{inputImage}(x',y')) where diff --git a/modules/video/include/opencv2/video/video.hpp b/modules/video/include/opencv2/video.hpp similarity index 100% rename from modules/video/include/opencv2/video/video.hpp rename to modules/video/include/opencv2/video.hpp diff --git a/modules/video/include/opencv2/video/background_segm.hpp b/modules/video/include/opencv2/video/background_segm.hpp index 5d298d4753..91e9900aaf 100644 --- a/modules/video/include/opencv2/video/background_segm.hpp +++ b/modules/video/include/opencv2/video/background_segm.hpp @@ -43,7 +43,7 @@ #ifndef __OPENCV_BACKGROUND_SEGM_HPP__ #define __OPENCV_BACKGROUND_SEGM_HPP__ -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" #include namespace cv { diff --git a/modules/video/include/opencv2/video/tracking.hpp b/modules/video/include/opencv2/video/tracking.hpp index b4270d1f1c..509ecda5c0 100644 --- a/modules/video/include/opencv2/video/tracking.hpp +++ b/modules/video/include/opencv2/video/tracking.hpp @@ -43,8 +43,8 @@ #ifndef __OPENCV_TRACKING_HPP__ #define __OPENCV_TRACKING_HPP__ -#include "opencv2/core/core.hpp" -#include "opencv2/imgproc/imgproc.hpp" +#include "opencv2/core.hpp" +#include "opencv2/imgproc.hpp" #ifdef __cplusplus extern "C" { diff --git a/modules/video/perf/perf_precomp.hpp b/modules/video/perf/perf_precomp.hpp index e1c2b566bf..94f8d92234 100644 --- a/modules/video/perf/perf_precomp.hpp +++ b/modules/video/perf/perf_precomp.hpp @@ -9,10 +9,10 @@ #ifndef __OPENCV_VIDEO_PRECOMP_HPP__ #define __OPENCV_VIDEO_PRECOMP_HPP__ -#include -#include -#include -#include "opencv2/ts/ts.hpp" +#include +#include +#include +#include "opencv2/ts.hpp" #ifdef GTEST_CREATE_SHARED_LIBRARY #error no modules except ts should have GTEST_CREATE_SHARED_LIBRARY defined diff --git a/modules/video/src/video_init.cpp b/modules/video/src/video_init.cpp index 0f3cec144c..189f4a36ba 100644 --- a/modules/video/src/video_init.cpp +++ b/modules/video/src/video_init.cpp @@ -41,7 +41,7 @@ //M*/ #include "precomp.hpp" -#include "opencv2/video/video.hpp" +#include "opencv2/video.hpp" namespace cv { diff --git a/modules/video/test/test_precomp.hpp b/modules/video/test/test_precomp.hpp index a4b869a52f..7025dff8f7 100644 --- a/modules/video/test/test_precomp.hpp +++ b/modules/video/test/test_precomp.hpp @@ -9,12 +9,11 @@ #ifndef __OPENCV_TEST_PRECOMP_HPP__ #define __OPENCV_TEST_PRECOMP_HPP__ -#include "opencv2/ts/ts.hpp" -#include "opencv2/imgproc/imgproc.hpp" +#include "opencv2/ts.hpp" +#include "opencv2/imgproc.hpp" #include "opencv2/imgproc/imgproc_c.h" -#include "opencv2/video/tracking.hpp" -#include "opencv2/video/background_segm.hpp" -#include "opencv2/highgui/highgui.hpp" +#include "opencv2/video.hpp" +#include "opencv2/highgui.hpp" #include #endif diff --git a/modules/videostab/include/opencv2/videostab/videostab.hpp b/modules/videostab/include/opencv2/videostab.hpp similarity index 100% rename from modules/videostab/include/opencv2/videostab/videostab.hpp rename to modules/videostab/include/opencv2/videostab.hpp diff --git a/modules/videostab/include/opencv2/videostab/deblurring.hpp b/modules/videostab/include/opencv2/videostab/deblurring.hpp index d2ab43824b..7359f8ee35 100644 --- a/modules/videostab/include/opencv2/videostab/deblurring.hpp +++ b/modules/videostab/include/opencv2/videostab/deblurring.hpp @@ -44,7 +44,7 @@ #define __OPENCV_VIDEOSTAB_DEBLURRING_HPP__ #include -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" namespace cv { diff --git a/modules/videostab/include/opencv2/videostab/fast_marching.hpp b/modules/videostab/include/opencv2/videostab/fast_marching.hpp index 23c5df3ab6..b948c887cc 100644 --- a/modules/videostab/include/opencv2/videostab/fast_marching.hpp +++ b/modules/videostab/include/opencv2/videostab/fast_marching.hpp @@ -46,7 +46,7 @@ #include #include #include -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" namespace cv { diff --git a/modules/videostab/include/opencv2/videostab/frame_source.hpp b/modules/videostab/include/opencv2/videostab/frame_source.hpp index 4e0fec2a4d..1198231969 100644 --- a/modules/videostab/include/opencv2/videostab/frame_source.hpp +++ b/modules/videostab/include/opencv2/videostab/frame_source.hpp @@ -45,7 +45,7 @@ #include #include -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" namespace cv { diff --git a/modules/videostab/include/opencv2/videostab/global_motion.hpp b/modules/videostab/include/opencv2/videostab/global_motion.hpp index 647e6ecfbe..5e57081386 100644 --- a/modules/videostab/include/opencv2/videostab/global_motion.hpp +++ b/modules/videostab/include/opencv2/videostab/global_motion.hpp @@ -46,15 +46,15 @@ #include #include #include -#include "opencv2/core/core.hpp" -#include "opencv2/features2d/features2d.hpp" +#include "opencv2/core.hpp" +#include "opencv2/features2d.hpp" #include "opencv2/opencv_modules.hpp" #include "opencv2/videostab/optical_flow.hpp" #include "opencv2/videostab/motion_core.hpp" #include "opencv2/videostab/outlier_rejection.hpp" #ifdef HAVE_OPENCV_GPU - #include "opencv2/gpu/gpu.hpp" + #include "opencv2/gpu.hpp" #endif namespace cv diff --git a/modules/videostab/include/opencv2/videostab/inpainting.hpp b/modules/videostab/include/opencv2/videostab/inpainting.hpp index 6455b14197..402745e7e1 100644 --- a/modules/videostab/include/opencv2/videostab/inpainting.hpp +++ b/modules/videostab/include/opencv2/videostab/inpainting.hpp @@ -44,11 +44,11 @@ #define __OPENCV_VIDEOSTAB_INPAINTINT_HPP__ #include -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" #include "opencv2/videostab/optical_flow.hpp" #include "opencv2/videostab/fast_marching.hpp" #include "opencv2/videostab/global_motion.hpp" -#include "opencv2/photo/photo.hpp" +#include "opencv2/photo.hpp" namespace cv { diff --git a/modules/videostab/include/opencv2/videostab/log.hpp b/modules/videostab/include/opencv2/videostab/log.hpp index ce6fadf803..9dfed5205f 100644 --- a/modules/videostab/include/opencv2/videostab/log.hpp +++ b/modules/videostab/include/opencv2/videostab/log.hpp @@ -43,7 +43,7 @@ #ifndef __OPENCV_VIDEOSTAB_LOG_HPP__ #define __OPENCV_VIDEOSTAB_LOG_HPP__ -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" namespace cv { diff --git a/modules/videostab/include/opencv2/videostab/motion_core.hpp b/modules/videostab/include/opencv2/videostab/motion_core.hpp index 7d9981d9c2..c72e34fba8 100644 --- a/modules/videostab/include/opencv2/videostab/motion_core.hpp +++ b/modules/videostab/include/opencv2/videostab/motion_core.hpp @@ -44,7 +44,7 @@ #define __OPENCV_VIDEOSTAB_MOTION_CORE_HPP__ #include -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" namespace cv { diff --git a/modules/videostab/include/opencv2/videostab/motion_stabilizing.hpp b/modules/videostab/include/opencv2/videostab/motion_stabilizing.hpp index eb3199482e..6b8895f0b1 100644 --- a/modules/videostab/include/opencv2/videostab/motion_stabilizing.hpp +++ b/modules/videostab/include/opencv2/videostab/motion_stabilizing.hpp @@ -45,7 +45,7 @@ #include #include -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" #include "opencv2/videostab/global_motion.hpp" namespace cv diff --git a/modules/videostab/include/opencv2/videostab/optical_flow.hpp b/modules/videostab/include/opencv2/videostab/optical_flow.hpp index e11b0815d7..61f38fdb62 100644 --- a/modules/videostab/include/opencv2/videostab/optical_flow.hpp +++ b/modules/videostab/include/opencv2/videostab/optical_flow.hpp @@ -43,11 +43,11 @@ #ifndef __OPENCV_VIDEOSTAB_OPTICAL_FLOW_HPP__ #define __OPENCV_VIDEOSTAB_OPTICAL_FLOW_HPP__ -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" #include "opencv2/opencv_modules.hpp" #ifdef HAVE_OPENCV_GPU - #include "opencv2/gpu/gpu.hpp" + #include "opencv2/gpu.hpp" #endif namespace cv diff --git a/modules/videostab/include/opencv2/videostab/outlier_rejection.hpp b/modules/videostab/include/opencv2/videostab/outlier_rejection.hpp index a21c05d8ec..a9c7578fce 100644 --- a/modules/videostab/include/opencv2/videostab/outlier_rejection.hpp +++ b/modules/videostab/include/opencv2/videostab/outlier_rejection.hpp @@ -44,7 +44,7 @@ #define __OPENCV_VIDEOSTAB_OUTLIER_REJECTION_HPP__ #include -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" #include "opencv2/videostab/motion_core.hpp" namespace cv diff --git a/modules/videostab/include/opencv2/videostab/ring_buffer.hpp b/modules/videostab/include/opencv2/videostab/ring_buffer.hpp index c03052cdde..a820edef9e 100644 --- a/modules/videostab/include/opencv2/videostab/ring_buffer.hpp +++ b/modules/videostab/include/opencv2/videostab/ring_buffer.hpp @@ -44,7 +44,7 @@ #define __OPENCV_VIDEOSTAB_RING_BUFFER_HPP__ #include -#include "opencv2/imgproc/imgproc.hpp" +#include "opencv2/imgproc.hpp" namespace cv { diff --git a/modules/videostab/include/opencv2/videostab/stabilizer.hpp b/modules/videostab/include/opencv2/videostab/stabilizer.hpp index 4707d70d44..c13718f0b6 100644 --- a/modules/videostab/include/opencv2/videostab/stabilizer.hpp +++ b/modules/videostab/include/opencv2/videostab/stabilizer.hpp @@ -45,8 +45,8 @@ #include #include -#include "opencv2/core/core.hpp" -#include "opencv2/imgproc/imgproc.hpp" +#include "opencv2/core.hpp" +#include "opencv2/imgproc.hpp" #include "opencv2/videostab/global_motion.hpp" #include "opencv2/videostab/motion_stabilizing.hpp" #include "opencv2/videostab/frame_source.hpp" diff --git a/modules/videostab/include/opencv2/videostab/wobble_suppression.hpp b/modules/videostab/include/opencv2/videostab/wobble_suppression.hpp index 48fa4de4f0..f38de85049 100644 --- a/modules/videostab/include/opencv2/videostab/wobble_suppression.hpp +++ b/modules/videostab/include/opencv2/videostab/wobble_suppression.hpp @@ -44,12 +44,12 @@ #define __OPENCV_VIDEOSTAB_WOBBLE_SUPPRESSION_HPP__ #include -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" #include "opencv2/videostab/global_motion.hpp" #include "opencv2/videostab/log.hpp" #ifdef HAVE_OPENCV_GPU - #include "opencv2/gpu/gpu.hpp" + #include "opencv2/gpu.hpp" #endif namespace cv diff --git a/modules/videostab/src/frame_source.cpp b/modules/videostab/src/frame_source.cpp index 5037213aba..b1dc9723cd 100644 --- a/modules/videostab/src/frame_source.cpp +++ b/modules/videostab/src/frame_source.cpp @@ -46,7 +46,7 @@ #include "opencv2/opencv_modules.hpp" #ifdef HAVE_OPENCV_HIGHGUI -# include "opencv2/highgui/highgui.hpp" +# include "opencv2/highgui.hpp" #endif namespace cv diff --git a/modules/videostab/src/optical_flow.cpp b/modules/videostab/src/optical_flow.cpp index 90aa7b5eba..f5c8288e7e 100644 --- a/modules/videostab/src/optical_flow.cpp +++ b/modules/videostab/src/optical_flow.cpp @@ -41,7 +41,7 @@ //M*/ #include "precomp.hpp" -#include "opencv2/video/video.hpp" +#include "opencv2/video.hpp" #include "opencv2/videostab/optical_flow.hpp" #include "opencv2/videostab/ring_buffer.hpp" diff --git a/modules/videostab/src/outlier_rejection.cpp b/modules/videostab/src/outlier_rejection.cpp index 6509a87669..ee37a93036 100644 --- a/modules/videostab/src/outlier_rejection.cpp +++ b/modules/videostab/src/outlier_rejection.cpp @@ -41,7 +41,6 @@ //M*/ #include "precomp.hpp" -#include "opencv2/core/core.hpp" #include "opencv2/videostab/outlier_rejection.hpp" namespace cv diff --git a/modules/videostab/src/precomp.hpp b/modules/videostab/src/precomp.hpp index 848c54836a..bf2d2114ac 100644 --- a/modules/videostab/src/precomp.hpp +++ b/modules/videostab/src/precomp.hpp @@ -51,11 +51,11 @@ #include #include #include -#include "opencv2/core/core.hpp" -#include "opencv2/imgproc/imgproc.hpp" -#include "opencv2/video/video.hpp" -#include "opencv2/features2d/features2d.hpp" -#include "opencv2/calib3d/calib3d.hpp" +#include "opencv2/core.hpp" +#include "opencv2/imgproc.hpp" +#include "opencv2/video.hpp" +#include "opencv2/features2d.hpp" +#include "opencv2/calib3d.hpp" // some aux. functions diff --git a/modules/world/include/opencv2/world/world.hpp b/modules/world/include/opencv2/world.hpp similarity index 98% rename from modules/world/include/opencv2/world/world.hpp rename to modules/world/include/opencv2/world.hpp index b4bff33a62..2442f2c27a 100644 --- a/modules/world/include/opencv2/world/world.hpp +++ b/modules/world/include/opencv2/world.hpp @@ -43,7 +43,7 @@ #ifndef __OPENCV_WORLD_HPP__ #define __OPENCV_WORLD_HPP__ -#include "opencv2/core/core.hpp" +#include "opencv2/core.hpp" #ifdef __cplusplus namespace cv diff --git a/modules/world/src/precomp.hpp b/modules/world/src/precomp.hpp index 263095700d..343b875979 100644 --- a/modules/world/src/precomp.hpp +++ b/modules/world/src/precomp.hpp @@ -49,18 +49,18 @@ #include "opencv2/opencv_modules.hpp" #ifdef HAVE_OPENCV_VIDEO -#include "opencv2/video/video.hpp" +#include "opencv2/video.hpp" #endif #ifdef HAVE_OPENCV_FEATURES2D -#include "opencv2/features2d/features2d.hpp" +#include "opencv2/features2d.hpp" #endif #ifdef HAVE_OPENCV_NONFREE -#include "opencv2/nonfree/nonfree.hpp" +#include "opencv2/nonfree.hpp" #endif #ifdef HAVE_OPENCV_ML -#include "opencv2/ml/ml.hpp" +#include "opencv2/ml.hpp" #endif -#include "opencv2/world/world.hpp" +#include "opencv2/world.hpp" #endif diff --git a/samples/cpp/stitching.cpp b/samples/cpp/stitching.cpp index b4980507b6..1ee6bdb7ce 100644 --- a/samples/cpp/stitching.cpp +++ b/samples/cpp/stitching.cpp @@ -42,8 +42,8 @@ #include #include -#include "opencv2/highgui/highgui.hpp" -#include "opencv2/stitching/stitcher.hpp" +#include "opencv2/highgui.hpp" +#include "opencv2/stitching.hpp" using namespace std; using namespace cv; diff --git a/samples/cpp/videostab.cpp b/samples/cpp/videostab.cpp index ee967be0eb..effd9e61f4 100644 --- a/samples/cpp/videostab.cpp +++ b/samples/cpp/videostab.cpp @@ -3,11 +3,11 @@ #include #include #include -#include "opencv2/core/core.hpp" -#include "opencv2/video/video.hpp" -#include "opencv2/imgproc/imgproc.hpp" -#include "opencv2/highgui/highgui.hpp" -#include "opencv2/videostab/videostab.hpp" +#include "opencv2/core.hpp" +#include "opencv2/video.hpp" +#include "opencv2/imgproc.hpp" +#include "opencv2/highgui.hpp" +#include "opencv2/videostab.hpp" #include "opencv2/opencv_modules.hpp" #define arg(name) cmd.get(name) diff --git a/samples/gpu/alpha_comp.cpp b/samples/gpu/alpha_comp.cpp index 8426ccab52..ca6937e1c2 100644 --- a/samples/gpu/alpha_comp.cpp +++ b/samples/gpu/alpha_comp.cpp @@ -1,6 +1,6 @@ #include -#include "opencv2/core/opengl_interop.hpp" +#include "opencv2/core/opengl.hpp" #include "opencv2/highgui/highgui.hpp" #include "opencv2/gpu/gpu.hpp" diff --git a/samples/gpu/opengl.cpp b/samples/gpu/opengl.cpp index 5b84a5bef5..80eb44b539 100644 --- a/samples/gpu/opengl.cpp +++ b/samples/gpu/opengl.cpp @@ -24,7 +24,7 @@ int main() #endif #include "opencv2/core/core.hpp" -#include "opencv2/core/opengl_interop.hpp" +#include "opencv2/core/opengl.hpp" #include "opencv2/core/gpumat.hpp" #include "opencv2/highgui/highgui.hpp" diff --git a/samples/gpu/video_reader.cpp b/samples/gpu/video_reader.cpp index 9676104753..a4c068516d 100644 --- a/samples/gpu/video_reader.cpp +++ b/samples/gpu/video_reader.cpp @@ -5,7 +5,7 @@ #include #include -#include +#include #include #include #include