diff --git a/cmake/OpenCVPackaging.cmake b/cmake/OpenCVPackaging.cmake index e97f40e1ae..a0ab95a814 100644 --- a/cmake/OpenCVPackaging.cmake +++ b/cmake/OpenCVPackaging.cmake @@ -123,7 +123,7 @@ endif() set(STD_OPENCV_LIBS opencv-data) set(STD_OPENCV_DEV libopencv-dev) -foreach(module 3d calib core dnn features flann highgui +foreach(module geometry calib core dnn features flann highgui imgcodecs imgproc ml objdetect photo stereo stitching ts video videoio) if(HAVE_opencv_${module}) diff --git a/doc/tutorials/3d/point_cloud/point_cloud.markdown b/doc/tutorials/geometry/point_cloud/point_cloud.markdown similarity index 100% rename from doc/tutorials/3d/point_cloud/point_cloud.markdown rename to doc/tutorials/geometry/point_cloud/point_cloud.markdown diff --git a/doc/tutorials/3d/point_cloud/teapot_grid.jpg b/doc/tutorials/geometry/point_cloud/teapot_grid.jpg similarity index 100% rename from doc/tutorials/3d/point_cloud/teapot_grid.jpg rename to doc/tutorials/geometry/point_cloud/teapot_grid.jpg diff --git a/doc/tutorials/3d/point_cloud/teapot_mesh.jpg b/doc/tutorials/geometry/point_cloud/teapot_mesh.jpg similarity index 100% rename from doc/tutorials/3d/point_cloud/teapot_mesh.jpg rename to doc/tutorials/geometry/point_cloud/teapot_mesh.jpg diff --git a/doc/tutorials/3d/point_cloud/tutorial_point_cloud_teapot.jpg b/doc/tutorials/geometry/point_cloud/tutorial_point_cloud_teapot.jpg similarity index 100% rename from doc/tutorials/3d/point_cloud/tutorial_point_cloud_teapot.jpg rename to doc/tutorials/geometry/point_cloud/tutorial_point_cloud_teapot.jpg diff --git a/doc/tutorials/3d/table_of_content_3d.markdown b/doc/tutorials/geometry/table_of_content_geometry.markdown similarity index 55% rename from doc/tutorials/3d/table_of_content_3d.markdown rename to doc/tutorials/geometry/table_of_content_geometry.markdown index af4990cced..76abae1efa 100644 --- a/doc/tutorials/3d/table_of_content_3d.markdown +++ b/doc/tutorials/geometry/table_of_content_geometry.markdown @@ -1,5 +1,5 @@ -3d processing and visualisation (3d module) {#tutorial_table_of_content_3d} +Computational geometry module {#tutorial_table_of_content_geometry} ========================================================== - @subpage tutorial_point_cloud diff --git a/doc/tutorials/introduction/config_reference/config_reference.markdown b/doc/tutorials/introduction/config_reference/config_reference.markdown index 8b4188bb4e..84fb7b5cf7 100644 --- a/doc/tutorials/introduction/config_reference/config_reference.markdown +++ b/doc/tutorials/introduction/config_reference/config_reference.markdown @@ -156,17 +156,17 @@ cmake \ Each module is a subdirectory of the `modules` directory. It is possible to disable one module: ```.sh -cmake -DBUILD_opencv_3d=OFF ../opencv +cmake -DBUILD_opencv_geometry=OFF ../opencv ``` The opposite option is to build only specified modules and all modules they depend on: ```.sh -cmake -DBUILD_LIST=calib3d,videoio,ts ../opencv +cmake -DBUILD_LIST=geometry,videoio,ts ../opencv ``` In this example we requested 3 modules and configuration script has determined all dependencies automatically: ``` -- OpenCV modules: --- To be built: calib3d core features flann highgui imgcodecs imgproc ts videoio +-- To be built: core features flann geometry highgui imgcodecs imgproc ts videoio ``` diff --git a/doc/tutorials/introduction/linux_eclipse/linux_eclipse.markdown b/doc/tutorials/introduction/linux_eclipse/linux_eclipse.markdown index 06561eafef..4a2d85ef26 100644 --- a/doc/tutorials/introduction/linux_eclipse/linux_eclipse.markdown +++ b/doc/tutorials/introduction/linux_eclipse/linux_eclipse.markdown @@ -114,7 +114,7 @@ Making a project since I plan to use the whole bunch: opencv_core opencv_imgproc opencv_imgcodecs opencv_highgui opencv_videoio opencv_video opencv_features - opencv_3d opencv_objdetect opencv_flann + opencv_geometry opencv_objdetect opencv_flann ![](images/a10.png) @@ -125,7 +125,7 @@ Making a project @endcode My output (in case you want to check) was: @code{.bash} - -L/usr/local/lib -lopencv_core -lopencv_imgproc -lopencv_highgui -lopencv_video -lopencv_features -lopencv_3d -lopencv_calib -lopencv_stereo -lopencv_objdetect -lopencv_videoio -lopencv_imgcodecs -lopencv_flann + -L/usr/local/lib -lopencv_core -lopencv_imgproc -lopencv_highgui -lopencv_video -lopencv_features -lopencv_geometry -lopencv_calib -lopencv_stereo -lopencv_objdetect -lopencv_videoio -lopencv_imgcodecs -lopencv_flann @endcode Now you are done. Click **OK** diff --git a/doc/tutorials/tutorials.markdown b/doc/tutorials/tutorials.markdown index dcf20fa727..c8538ba4b9 100644 --- a/doc/tutorials/tutorials.markdown +++ b/doc/tutorials/tutorials.markdown @@ -11,7 +11,7 @@ OpenCV Tutorials {#tutorial_root} - @subpage tutorial_table_of_content_dnn - infer neural networks using built-in _dnn_ module - @subpage tutorial_table_of_content_other - other modules (stitching, video) - @subpage tutorial_table_of_content_ios - running OpenCV on an iDevice -- @subpage tutorial_table_of_content_3d - 3d objects processing and visualisation +- @subpage tutorial_table_of_content_geometry - 2d and 3d geometry primitives and point clouds processing - @subpage tutorial_table_of_content_photo - photo module functions (hdr_image, ccm) @cond CUDA_MODULES - @subpage tutorial_table_of_content_gpu - utilizing power of video card to run CV algorithms diff --git a/modules/3d/CMakeLists.txt b/modules/3d/CMakeLists.txt deleted file mode 100644 index 95b45b1248..0000000000 --- a/modules/3d/CMakeLists.txt +++ /dev/null @@ -1,16 +0,0 @@ -set(the_description "Camera Calibration and 3D Reconstruction") - -ocv_add_dispatched_file(undistort SSE2 AVX2) - -set(debug_modules "") -if(DEBUG_opencv_3d) - list(APPEND debug_modules opencv_highgui) -endif() -ocv_define_module(3d opencv_imgproc opencv_flann ${debug_modules} - WRAP java objc python js -) -ocv_target_link_libraries(${the_module} ${LAPACK_LIBRARIES}) - -if(NOT HAVE_EIGEN) - message(STATUS "3d: Eigen support is disabled. Eigen is Required for Posegraph optimization") -endif() diff --git a/modules/3d/misc/js/gen_dict.json b/modules/3d/misc/js/gen_dict.json deleted file mode 100644 index b590b3ceec..0000000000 --- a/modules/3d/misc/js/gen_dict.json +++ /dev/null @@ -1,21 +0,0 @@ -{ - "whitelist": - { - "": [ - "findHomography", - "drawFrameAxes", - "estimateAffine2D", - "getDefaultNewCameraMatrix", - "initUndistortRectifyMap", - "Rodrigues", - "solvePnP", - "solvePnPRansac", - "solvePnPRefineLM", - "projectPoints", - "undistort", - "fisheye_initUndistortRectifyMap", - "fisheye_projectPoints" - ], - "UsacParams": ["UsacParams"] - } -} diff --git a/modules/calib/CMakeLists.txt b/modules/calib/CMakeLists.txt index 2af9a78e45..234e48b387 100644 --- a/modules/calib/CMakeLists.txt +++ b/modules/calib/CMakeLists.txt @@ -4,6 +4,6 @@ set(debug_modules "") if(DEBUG_opencv_calib) list(APPEND debug_modules opencv_highgui) endif() -ocv_define_module(calib opencv_imgproc opencv_objdetect opencv_flann opencv_3d opencv_stereo ${debug_modules} +ocv_define_module(calib opencv_imgproc opencv_objdetect opencv_flann opencv_geometry opencv_stereo ${debug_modules} WRAP java objc python js ) diff --git a/modules/calib/include/opencv2/calib3d.hpp b/modules/calib/include/opencv2/calib3d.hpp index 60eb96c356..5ee2c3180a 100644 --- a/modules/calib/include/opencv2/calib3d.hpp +++ b/modules/calib/include/opencv2/calib3d.hpp @@ -7,7 +7,7 @@ #ifndef OPENCV_CALIB3D_HPP #define OPENCV_CALIB3D_HPP -#include "opencv2/3d.hpp" +#include "opencv2/geometry.hpp" #include "opencv2/stereo.hpp" #include "opencv2/calib.hpp" diff --git a/modules/calib/misc/java/test/CalibTest.java b/modules/calib/misc/java/test/CalibTest.java index 065f1d76b8..1640664013 100644 --- a/modules/calib/misc/java/test/CalibTest.java +++ b/modules/calib/misc/java/test/CalibTest.java @@ -2,7 +2,6 @@ package org.opencv.test.calib; import java.util.ArrayList; -import org.opencv.cv3d.Cv3d; import org.opencv.calib.Calib; import org.opencv.core.Core; import org.opencv.core.CvType; diff --git a/modules/calib/src/precomp.hpp b/modules/calib/src/precomp.hpp index dc4cc5722e..31893cf38d 100644 --- a/modules/calib/src/precomp.hpp +++ b/modules/calib/src/precomp.hpp @@ -47,7 +47,7 @@ #include "opencv2/core/private.hpp" #include "opencv2/calib.hpp" -#include "opencv2/3d.hpp" +#include "opencv2/geometry.hpp" #include "opencv2/imgproc.hpp" #include "opencv2/features.hpp" diff --git a/modules/calib/test/test_precomp.hpp b/modules/calib/test/test_precomp.hpp index 0b4fa601e2..6933ed166b 100644 --- a/modules/calib/test/test_precomp.hpp +++ b/modules/calib/test/test_precomp.hpp @@ -8,7 +8,7 @@ #include #include "opencv2/ts.hpp" -#include "opencv2/3d.hpp" +#include "opencv2/geometry.hpp" #include "opencv2/calib.hpp" #endif diff --git a/modules/dnn/CMakeLists.txt b/modules/dnn/CMakeLists.txt index df54e16e2e..f1f9e13695 100644 --- a/modules/dnn/CMakeLists.txt +++ b/modules/dnn/CMakeLists.txt @@ -19,7 +19,7 @@ ocv_add_dispatched_file_force_all("layers/cpu_kernels/transpose_kernels" AVX AVX ocv_add_dispatched_file_force_all("layers/cpu_kernels/gridsample_kernels" AVX AVX2 NEON RVV LASX) ocv_add_dispatched_file_force_all("layers/cpu_kernels/nary_eltwise_kernels" AVX AVX2 NEON RVV LASX) -ocv_add_module(dnn opencv_core opencv_imgproc opencv_3d WRAP python java objc js) +ocv_add_module(dnn opencv_core opencv_imgproc opencv_geometry WRAP python java objc js) include(${CMAKE_CURRENT_LIST_DIR}/cmake/plugin.cmake) diff --git a/modules/dnn/src/model.cpp b/modules/dnn/src/model.cpp index 5b1707b793..d766341398 100644 --- a/modules/dnn/src/model.cpp +++ b/modules/dnn/src/model.cpp @@ -10,7 +10,7 @@ #include #include -#include +#include namespace cv { namespace dnn { diff --git a/modules/dnn/src/nms.cpp b/modules/dnn/src/nms.cpp index 0f9de33ba5..5fac34d04f 100644 --- a/modules/dnn/src/nms.cpp +++ b/modules/dnn/src/nms.cpp @@ -9,7 +9,7 @@ #include "nms.inl.hpp" #include -#include +#include namespace cv { namespace dnn { CV__DNN_INLINE_NS_BEGIN diff --git a/modules/dnn/test/test_common.impl.hpp b/modules/dnn/test/test_common.impl.hpp index 0889e93668..4ba8127f68 100644 --- a/modules/dnn/test/test_common.impl.hpp +++ b/modules/dnn/test/test_common.impl.hpp @@ -14,7 +14,7 @@ #include #include -#include +#include #ifdef _WIN32 #ifndef NOMINMAX diff --git a/modules/dnn/test/test_model.cpp b/modules/dnn/test/test_model.cpp index d9c994c793..9065b462c5 100644 --- a/modules/dnn/test/test_model.cpp +++ b/modules/dnn/test/test_model.cpp @@ -4,7 +4,7 @@ #include "test_precomp.hpp" #include -#include +#include #include "npy_blob.hpp" #include #include diff --git a/modules/features/CMakeLists.txt b/modules/features/CMakeLists.txt index a337e38104..c6c73ffd10 100644 --- a/modules/features/CMakeLists.txt +++ b/modules/features/CMakeLists.txt @@ -6,7 +6,7 @@ set(debug_modules "") if(DEBUG_opencv_features) list(APPEND debug_modules opencv_highgui) endif() -ocv_define_module(features opencv_imgproc opencv_3d ${debug_modules} OPTIONAL opencv_flann WRAP java objc python js) +ocv_define_module(features opencv_imgproc opencv_geometry ${debug_modules} OPTIONAL opencv_flann WRAP java objc python js) ocv_install_3rdparty_licenses(mscr "${CMAKE_CURRENT_SOURCE_DIR}/3rdparty/mscr/chi_table_LICENSE.txt") ocv_install_3rdparty_licenses(annoylib "${CMAKE_CURRENT_SOURCE_DIR}/3rdparty/annoy/LICENSE") diff --git a/modules/features/misc/java/test/FeaturesTest.java b/modules/features/misc/java/test/FeaturesTest.java index a46296a199..0a2175a2d8 100644 --- a/modules/features/misc/java/test/FeaturesTest.java +++ b/modules/features/misc/java/test/FeaturesTest.java @@ -4,7 +4,7 @@ import java.util.ArrayList; import java.util.Arrays; import java.util.List; -import org.opencv.cv3d.Cv3d; +import org.opencv.geometry.Geometry; import org.opencv.core.CvType; import org.opencv.core.Mat; import org.opencv.core.MatOfInt; @@ -135,7 +135,7 @@ public class FeaturesTest extends OpenCVTestCase { MatOfPoint2f points1 = new MatOfPoint2f(lp1.toArray(new Point[0])); MatOfPoint2f points2 = new MatOfPoint2f(lp2.toArray(new Point[0])); - Mat hmg = Cv3d.findHomography(points1, points2, Cv3d.RANSAC, 3); + Mat hmg = Geometry.findHomography(points1, points2, Geometry.RANSAC, 3); assertMatEqual(Mat.eye(3, 3, CvType.CV_64F), hmg, EPS); diff --git a/modules/features/src/precomp.hpp b/modules/features/src/precomp.hpp index 4baa886fe1..007ce3a2b8 100644 --- a/modules/features/src/precomp.hpp +++ b/modules/features/src/precomp.hpp @@ -45,7 +45,7 @@ #include "opencv2/features.hpp" #include "opencv2/imgproc.hpp" -#include "opencv2/3d.hpp" +#include "opencv2/geometry.hpp" #include "opencv2/core/utility.hpp" #include "opencv2/core/private.hpp" diff --git a/modules/geometry/CMakeLists.txt b/modules/geometry/CMakeLists.txt new file mode 100644 index 0000000000..d280f1a467 --- /dev/null +++ b/modules/geometry/CMakeLists.txt @@ -0,0 +1,16 @@ +set(the_description "Computational geometry primitives") + +ocv_add_dispatched_file(undistort SSE2 AVX2) + +set(debug_modules "") +if(DEBUG_opencv_geometry) + list(APPEND debug_modules opencv_highgui) +endif() +ocv_define_module(geometry opencv_imgproc opencv_flann ${debug_modules} + WRAP java objc python js +) +ocv_target_link_libraries(${the_module} ${LAPACK_LIBRARIES}) + +if(NOT HAVE_EIGEN) + message(STATUS "Geometry: Eigen support is disabled. Eigen is Required for Posegraph optimization") +endif() diff --git a/modules/3d/doc/3d.bib b/modules/geometry/doc/geometry.bib similarity index 100% rename from modules/3d/doc/3d.bib rename to modules/geometry/doc/geometry.bib diff --git a/modules/3d/doc/pics/pinhole_homogeneous_transformation.jpg b/modules/geometry/doc/pics/pinhole_homogeneous_transformation.jpg similarity index 100% rename from modules/3d/doc/pics/pinhole_homogeneous_transformation.jpg rename to modules/geometry/doc/pics/pinhole_homogeneous_transformation.jpg diff --git a/modules/3d/doc/solvePnP.markdown b/modules/geometry/doc/solvePnP.markdown similarity index 100% rename from modules/3d/doc/solvePnP.markdown rename to modules/geometry/doc/solvePnP.markdown diff --git a/modules/geometry/include/opencv2/geometry.hpp b/modules/geometry/include/opencv2/geometry.hpp new file mode 100644 index 0000000000..680cf34a0e --- /dev/null +++ b/modules/geometry/include/opencv2/geometry.hpp @@ -0,0 +1,20 @@ +// This file is part of OpenCV project. +// It is subject to the license terms in the LICENSE file found in the top-level directory +// of this distribution and at http://opencv.org/license.html + +#ifndef OPENCV_GEOMETRY_HPP +#define OPENCV_GEOMETRY_HPP + +/** +@defgroup geometry Computational geometry primitives module. +*/ + +//! @addtogroup geometry +//! @{ + +#include "opencv2/geometry/2d.hpp" +#include "opencv2/geometry/3d.hpp" + +//! @} geometry + +#endif diff --git a/modules/3d/include/opencv2/3d/2d.hpp b/modules/geometry/include/opencv2/geometry/2d.hpp similarity index 99% rename from modules/3d/include/opencv2/3d/2d.hpp rename to modules/geometry/include/opencv2/geometry/2d.hpp index 95378f7d7a..bc04b7826c 100644 --- a/modules/3d/include/opencv2/3d/2d.hpp +++ b/modules/geometry/include/opencv2/geometry/2d.hpp @@ -10,7 +10,7 @@ namespace cv { -//! @addtogroup imgproc_shape +//! @addtogroup geometry_shape //! @{ //! types of intersection between rectangles @@ -28,7 +28,7 @@ enum LineSegmentDetectorModes { //!< refined through increase of precision, decrement in size, etc. }; -//! @addtogroup imgproc_subdiv2d +//! @addtogroup geometry_subdiv2d //! @{ class CV_EXPORTS_W Subdiv2D @@ -304,9 +304,9 @@ protected: Point2f bottomRight; }; -//! @} imgproc_subdiv2d +//! @} geometry_subdiv2d -//! @addtogroup imgproc_feature +//! @addtogroup geometry_feature //! @{ /** @example samples/cpp/snippets/lsd_lines.cpp @@ -388,7 +388,7 @@ CV_EXPORTS_W Ptr createLineSegmentDetector( double sigma_scale = 0.6, double quant = 2.0, double ang_th = 22.5, double log_eps = 0, double density_th = 0.7, int n_bins = 1024); -//! @} imgproc_feature +//! @} geometry_feature /** @example samples/python/snippets/squares.py A n example using approxPolyDP function in python. * diff --git a/modules/3d/include/opencv2/3d.hpp b/modules/geometry/include/opencv2/geometry/3d.hpp similarity index 99% rename from modules/3d/include/opencv2/3d.hpp rename to modules/geometry/include/opencv2/geometry/3d.hpp index fabfdea4d2..8a2c70164e 100644 --- a/modules/3d/include/opencv2/3d.hpp +++ b/modules/geometry/include/opencv2/geometry/3d.hpp @@ -8,13 +8,12 @@ #include "opencv2/core.hpp" #include "opencv2/core/utils/logger.hpp" -#include "opencv2/3d/2d.hpp" -#include "opencv2/3d/depth.hpp" -#include "opencv2/3d/odometry.hpp" -#include "opencv2/3d/odometry_frame.hpp" -#include "opencv2/3d/odometry_settings.hpp" -#include "opencv2/3d/volume.hpp" -#include "opencv2/3d/ptcloud.hpp" +#include "opencv2/geometry/depth.hpp" +#include "opencv2/geometry/odometry.hpp" +#include "opencv2/geometry/odometry_frame.hpp" +#include "opencv2/geometry/odometry_settings.hpp" +#include "opencv2/geometry/volume.hpp" +#include "opencv2/geometry/ptcloud.hpp" /** @defgroup _3d 3D vision functionality diff --git a/modules/3d/include/opencv2/3d/depth.hpp b/modules/geometry/include/opencv2/geometry/depth.hpp similarity index 100% rename from modules/3d/include/opencv2/3d/depth.hpp rename to modules/geometry/include/opencv2/geometry/depth.hpp diff --git a/modules/3d/include/opencv2/3d/detail/kinfu_frame.hpp b/modules/geometry/include/opencv2/geometry/detail/kinfu_frame.hpp similarity index 100% rename from modules/3d/include/opencv2/3d/detail/kinfu_frame.hpp rename to modules/geometry/include/opencv2/geometry/detail/kinfu_frame.hpp diff --git a/modules/3d/include/opencv2/3d/detail/optimizer.hpp b/modules/geometry/include/opencv2/geometry/detail/optimizer.hpp similarity index 99% rename from modules/3d/include/opencv2/3d/detail/optimizer.hpp rename to modules/geometry/include/opencv2/geometry/detail/optimizer.hpp index 57f9af2148..d8d983522a 100644 --- a/modules/3d/include/opencv2/3d/detail/optimizer.hpp +++ b/modules/geometry/include/opencv2/geometry/detail/optimizer.hpp @@ -7,7 +7,7 @@ #include "opencv2/core/affine.hpp" #include "opencv2/core/quaternion.hpp" -#include "opencv2/3d.hpp" +#include "opencv2/geometry/3d.hpp" namespace cv { diff --git a/modules/3d/include/opencv2/3d/detail/submap.hpp b/modules/geometry/include/opencv2/geometry/detail/submap.hpp similarity index 99% rename from modules/3d/include/opencv2/3d/detail/submap.hpp rename to modules/geometry/include/opencv2/geometry/detail/submap.hpp index bf29118e87..e11256242b 100644 --- a/modules/3d/include/opencv2/3d/detail/submap.hpp +++ b/modules/geometry/include/opencv2/geometry/detail/submap.hpp @@ -7,7 +7,7 @@ #include #include -#include "opencv2/3d/detail/optimizer.hpp" +#include "opencv2/geometry/detail/optimizer.hpp" //TODO: remove it when it is rewritten to robust pose graph #include "opencv2/core/dualquaternion.hpp" diff --git a/modules/3d/include/opencv2/3d/mst.hpp b/modules/geometry/include/opencv2/geometry/mst.hpp similarity index 100% rename from modules/3d/include/opencv2/3d/mst.hpp rename to modules/geometry/include/opencv2/geometry/mst.hpp diff --git a/modules/3d/include/opencv2/3d/odometry.hpp b/modules/geometry/include/opencv2/geometry/odometry.hpp similarity index 100% rename from modules/3d/include/opencv2/3d/odometry.hpp rename to modules/geometry/include/opencv2/geometry/odometry.hpp diff --git a/modules/3d/include/opencv2/3d/odometry_frame.hpp b/modules/geometry/include/opencv2/geometry/odometry_frame.hpp similarity index 100% rename from modules/3d/include/opencv2/3d/odometry_frame.hpp rename to modules/geometry/include/opencv2/geometry/odometry_frame.hpp diff --git a/modules/3d/include/opencv2/3d/odometry_settings.hpp b/modules/geometry/include/opencv2/geometry/odometry_settings.hpp similarity index 100% rename from modules/3d/include/opencv2/3d/odometry_settings.hpp rename to modules/geometry/include/opencv2/geometry/odometry_settings.hpp diff --git a/modules/3d/include/opencv2/3d/ptcloud.hpp b/modules/geometry/include/opencv2/geometry/ptcloud.hpp similarity index 100% rename from modules/3d/include/opencv2/3d/ptcloud.hpp rename to modules/geometry/include/opencv2/geometry/ptcloud.hpp diff --git a/modules/3d/include/opencv2/3d/volume.hpp b/modules/geometry/include/opencv2/geometry/volume.hpp similarity index 100% rename from modules/3d/include/opencv2/3d/volume.hpp rename to modules/geometry/include/opencv2/geometry/volume.hpp diff --git a/modules/3d/include/opencv2/3d/volume_settings.hpp b/modules/geometry/include/opencv2/geometry/volume_settings.hpp similarity index 99% rename from modules/3d/include/opencv2/3d/volume_settings.hpp rename to modules/geometry/include/opencv2/geometry/volume_settings.hpp index b58c78c08b..829422008e 100644 --- a/modules/3d/include/opencv2/3d/volume_settings.hpp +++ b/modules/geometry/include/opencv2/geometry/volume_settings.hpp @@ -7,7 +7,7 @@ #define OPENCV_3D_VOLUME_SETTINGS_HPP #include -#include +#include namespace cv { diff --git a/modules/3d/misc/java/gen_dict.json b/modules/geometry/misc/java/gen_dict.json similarity index 100% rename from modules/3d/misc/java/gen_dict.json rename to modules/geometry/misc/java/gen_dict.json diff --git a/modules/3d/misc/java/test/Cv3dTest.java b/modules/geometry/misc/java/test/GeometryTest.java similarity index 91% rename from modules/3d/misc/java/test/Cv3dTest.java rename to modules/geometry/misc/java/test/GeometryTest.java index a360522b91..9e5b123267 100644 --- a/modules/3d/misc/java/test/Cv3dTest.java +++ b/modules/geometry/misc/java/test/GeometryTest.java @@ -1,10 +1,10 @@ -package org.opencv.test.cv3d; +package org.opencv.test.geometry; import java.util.ArrayList; import java.util.Arrays; import java.util.List; -import org.opencv.cv3d.Cv3d; +import org.opencv.geometry.Geometry; import org.opencv.core.Core; import org.opencv.core.CvType; import org.opencv.core.Mat; @@ -21,7 +21,7 @@ import org.opencv.core.RotatedRect; import org.opencv.test.OpenCVTestCase; import org.opencv.imgproc.Imgproc; -public class Cv3dTest extends OpenCVTestCase { +public class GeometryTest extends OpenCVTestCase { Size size; @@ -50,7 +50,7 @@ public class Cv3dTest extends OpenCVTestCase { Mat outTvec = new Mat(3, 1, CvType.CV_32F); outTvec.put(0, 0, 1.4560841, 1.0680628, 0.81598103); - Cv3d.composeRT(rvec1, tvec1, rvec2, tvec2, rvec3, tvec3); + Geometry.composeRT(rvec1, tvec1, rvec2, tvec2, rvec3, tvec3); assertMatEqual(outRvec, rvec3, EPS); assertMatEqual(outTvec, tvec3, EPS); @@ -192,7 +192,7 @@ public class Cv3dTest extends OpenCVTestCase { transformedPoints.put(i, 0, y, x); } - Mat hmg = Cv3d.findHomography(originalPoints, transformedPoints); + Mat hmg = Geometry.findHomography(originalPoints, transformedPoints); truth = new Mat(3, 3, CvType.CV_64F); truth.put(0, 0, 0, 1, 0, 1, 0, 0, 0, 0, 1); @@ -258,14 +258,14 @@ public class Cv3dTest extends OpenCVTestCase { r.put(0, 0, Math.PI, 0, 0); - Cv3d.Rodrigues(r, R); + Geometry.Rodrigues(r, R); truth = new Mat(3, 3, CvType.CV_32F); truth.put(0, 0, 1, 0, 0, 0, -1, 0, 0, 0, -1); assertMatEqual(truth, R, EPS); Mat r2 = new Mat(); - Cv3d.Rodrigues(R, r2); + Geometry.Rodrigues(R, r2); assertMatEqual(r, r2, EPS); } @@ -313,7 +313,7 @@ public class Cv3dTest extends OpenCVTestCase { Mat rvec = new Mat(); Mat tvec = new Mat(); - Cv3d.solvePnP(points3d, points2d, intrinsics, new MatOfDouble(), rvec, tvec); + Geometry.solvePnP(points3d, points2d, intrinsics, new MatOfDouble(), rvec, tvec); Mat truth_rvec = new Mat(3, 1, CvType.CV_64F); truth_rvec.put(0, 0, 0, Math.PI / 2, 0); @@ -391,7 +391,7 @@ public class Cv3dTest extends OpenCVTestCase { Mat lines = new Mat(); Mat truth = new Mat(1, 1, CvType.CV_32FC3); truth.put(0, 0, -0.70735186, 0.70686162, -0.70588124); - Cv3d.computeCorrespondEpilines(left, 1, fundamental, lines); + Geometry.computeCorrespondEpilines(left, 1, fundamental, lines); assertMatEqual(truth, lines, EPS); } @@ -424,7 +424,7 @@ public class Cv3dTest extends OpenCVTestCase { Mat reprojectionError = new Mat(2, 1, CvType.CV_64FC1); - Cv3d.solvePnPGeneric(points3d, points2d, intrinsics, new MatOfDouble(), rvecs, tvecs, false, Cv3d.SOLVEPNP_IPPE, rvec, tvec, reprojectionError); + Geometry.solvePnPGeneric(points3d, points2d, intrinsics, new MatOfDouble(), rvecs, tvecs, false, Geometry.SOLVEPNP_IPPE, rvec, tvec, reprojectionError); Mat truth_rvec = new Mat(3, 1, CvType.CV_64F); truth_rvec.put(0, 0, 0, Math.PI / 2, 0); @@ -437,14 +437,14 @@ public class Cv3dTest extends OpenCVTestCase { } public void testGetDefaultNewCameraMatrixMat() { - Mat mtx = Cv3d.getDefaultNewCameraMatrix(gray0); + Mat mtx = Geometry.getDefaultNewCameraMatrix(gray0); assertFalse(mtx.empty()); assertEquals(0, Core.countNonZero(mtx)); } public void testGetDefaultNewCameraMatrixMatSizeBoolean() { - Mat mtx = Cv3d.getDefaultNewCameraMatrix(gray0, size, true); + Mat mtx = Geometry.getDefaultNewCameraMatrix(gray0, size, true); assertFalse(mtx.empty()); assertFalse(0 == Core.countNonZero(mtx)); @@ -466,7 +466,7 @@ public class Cv3dTest extends OpenCVTestCase { Mat map2 = new Mat(); // TODO: complete this test - Cv3d.initUndistortRectifyMap(cameraMatrix, distCoeffs, R, newCameraMatrix, size, CvType.CV_32F, map1, map2); + Geometry.initUndistortRectifyMap(cameraMatrix, distCoeffs, R, newCameraMatrix, size, CvType.CV_32F, map1, map2); } public void testInitWideAngleProjMapMatMatSizeIntIntMatMat() { @@ -485,7 +485,7 @@ public class Cv3dTest extends OpenCVTestCase { truth.put(1, 0, 0, 0, 0); truth.put(2, 0, 0, 3, 0); // TODO: No documentation for this function - // Cv3d.initWideAngleProjMap(cameraMatrix, distCoeffs, imageSize, + // Geometry.initWideAngleProjMap(cameraMatrix, distCoeffs, imageSize, // 5, m1type, truthput1, truthput2); } @@ -512,7 +512,7 @@ public class Cv3dTest extends OpenCVTestCase { } }; - Cv3d.undistort(src, dst, cameraMatrix, distCoeffs); + Geometry.undistort(src, dst, cameraMatrix, distCoeffs); truth = new Mat(3, 3, CvType.CV_32F) { { @@ -540,7 +540,7 @@ public class Cv3dTest extends OpenCVTestCase { }; Mat newCameraMatrix = new Mat(3, 3, CvType.CV_32F, new Scalar(1)); - Cv3d.undistort(src, dst, cameraMatrix, distCoeffs, newCameraMatrix); + Geometry.undistort(src, dst, cameraMatrix, distCoeffs, newCameraMatrix); truth = new Mat(3, 3, CvType.CV_32F, new Scalar(3)); assertMatEqual(truth, dst, EPS); @@ -553,7 +553,7 @@ public class Cv3dTest extends OpenCVTestCase { Mat cameraMatrix = Mat.eye(3, 3, CvType.CV_64FC1); Mat distCoeffs = new Mat(8, 1, CvType.CV_64FC1, new Scalar(0)); - Cv3d.undistortPoints(src, dst, cameraMatrix, distCoeffs); + Geometry.undistortPoints(src, dst, cameraMatrix, distCoeffs); assertEquals(src.cols(), dst.rows()); assertEquals(src.rows(), dst.cols()); @@ -584,7 +584,7 @@ public class Cv3dTest extends OpenCVTestCase { K_new_truth.put(1,1, 373.6673784974842); K_new_truth.put(1,2, 538.794152656429); - Cv3d.fisheye_estimateNewCameraMatrixForUndistortRectify(K,D,new Size(1920,1080), + Geometry.fisheye_estimateNewCameraMatrixForUndistortRectify(K,D,new Size(1920,1080), new Mat().eye(3, 3, CvType.CV_64F), K_new, 0.0, new Size(1920,1080)); assertMatEqual(K_new, K_new_truth, EPS); @@ -595,7 +595,7 @@ public class Cv3dTest extends OpenCVTestCase { MatOfPoint2f approxCurve = new MatOfPoint2f(); - Cv3d.approxPolyDP(curve, approxCurve, EPS, true); + Geometry.approxPolyDP(curve, approxCurve, EPS, true); List approxCurveGold = new ArrayList(3); approxCurveGold.add(new Point(1, 3)); @@ -617,7 +617,7 @@ public class Cv3dTest extends OpenCVTestCase { MatOfInt hull = new MatOfInt(); - Cv3d.convexHull(points, hull); + Geometry.convexHull(points, hull); MatOfInt expHull = new MatOfInt( 0, 1, 2, 3 @@ -637,7 +637,7 @@ public class Cv3dTest extends OpenCVTestCase { MatOfInt hull = new MatOfInt(); - Cv3d.convexHull(points, hull, true); + Geometry.convexHull(points, hull, true); MatOfInt expHull = new MatOfInt( 3, 2, 1, 0 @@ -656,10 +656,10 @@ public class Cv3dTest extends OpenCVTestCase { ); MatOfInt hull = new MatOfInt(); - Cv3d.convexHull(points, hull); + Geometry.convexHull(points, hull); MatOfInt4 convexityDefects = new MatOfInt4(); - Cv3d.convexityDefects(points, hull, convexityDefects); + Geometry.convexityDefects(points, hull, convexityDefects); assertMatEqual(new MatOfInt4(3, 0, 5, 3620), convexityDefects.reshape(4, convexityDefects.cols())); } @@ -668,7 +668,7 @@ public class Cv3dTest extends OpenCVTestCase { MatOfPoint2f points = new MatOfPoint2f(new Point(0, 0), new Point(-1, 1), new Point(1, 1), new Point(1, -1), new Point(-1, -1)); RotatedRect rrect = new RotatedRect(); - rrect = Cv3d.fitEllipse(points); + rrect = Geometry.fitEllipse(points); double FIT_ELLIPSE_CENTER_EPS = 0.01; double FIT_ELLIPSE_SIZE_EPS = 0.4; @@ -686,7 +686,7 @@ public class Cv3dTest extends OpenCVTestCase { Mat linePoints = new Mat(4, 1, CvType.CV_32FC1); linePoints.put(0, 0, 0.53198653, 0.84675282, 2.5, 3.75); - Cv3d.fitLine(points, dst, Imgproc.DIST_L12, 0, 0.01, 0.01); + Geometry.fitLine(points, dst, Imgproc.DIST_L12, 0, 0.01, 0.01); assertMatEqual(linePoints, dst, EPS); } @@ -694,11 +694,11 @@ public class Cv3dTest extends OpenCVTestCase { public void testIsContourConvex() { MatOfPoint contour1 = new MatOfPoint(new Point(0, 0), new Point(10, 0), new Point(10, 10), new Point(5, 4)); - assertFalse(Cv3d.isContourConvex(contour1)); + assertFalse(Geometry.isContourConvex(contour1)); MatOfPoint contour2 = new MatOfPoint(new Point(0, 0), new Point(10, 0), new Point(10, 10), new Point(5, 6)); - assertTrue(Cv3d.isContourConvex(contour2)); + assertTrue(Geometry.isContourConvex(contour2)); } public void testMatchShapes() { @@ -707,7 +707,7 @@ public class Cv3dTest extends OpenCVTestCase { contour1.put(0, 0, 1, 1, 5, 1, 4, 3, 6, 2); contour2.put(0, 0, 1, 1, 6, 1, 4, 1, 2, 5); - double distance = Cv3d.matchShapes(contour1, contour2, Imgproc.CONTOURS_MATCH_I1, 1); + double distance = Geometry.matchShapes(contour1, contour2, Imgproc.CONTOURS_MATCH_I1, 1); assertEquals(2.81109697365334, distance, EPS); } @@ -715,7 +715,7 @@ public class Cv3dTest extends OpenCVTestCase { public void testMinAreaRect() { MatOfPoint2f points = new MatOfPoint2f(new Point(1, 1), new Point(5, 1), new Point(4, 3), new Point(6, 2)); - RotatedRect rrect = Cv3d.minAreaRect(points); + RotatedRect rrect = Geometry.minAreaRect(points); assertEquals(new Size(2, 5), rrect.size); assertEquals(-90., rrect.angle); @@ -727,7 +727,7 @@ public class Cv3dTest extends OpenCVTestCase { Point actualCenter = new Point(); float[] radius = new float[1]; - Cv3d.minEnclosingCircle(points, actualCenter, radius); + Geometry.minEnclosingCircle(points, actualCenter, radius); assertEquals(new Point(0, 0), actualCenter); assertEquals(100.0f, radius[0], 1.0); @@ -735,10 +735,10 @@ public class Cv3dTest extends OpenCVTestCase { public void testPointPolygonTest() { MatOfPoint2f contour = new MatOfPoint2f(new Point(0, 0), new Point(1, 3), new Point(3, 4), new Point(4, 3), new Point(2, 1)); - double sign1 = Cv3d.pointPolygonTest(contour, new Point(2, 2), false); + double sign1 = Geometry.pointPolygonTest(contour, new Point(2, 2), false); assertEquals(1.0, sign1); - double sign2 = Cv3d.pointPolygonTest(contour, new Point(4, 4), true); + double sign2 = Geometry.pointPolygonTest(contour, new Point(4, 4), true); assertEquals(-Math.sqrt(0.5), sign2); } } diff --git a/modules/3d/misc/java/test/Subdiv2DTest.java b/modules/geometry/misc/java/test/Subdiv2DTest.java similarity index 97% rename from modules/3d/misc/java/test/Subdiv2DTest.java rename to modules/geometry/misc/java/test/Subdiv2DTest.java index dd0f4e4749..232449dc41 100644 --- a/modules/3d/misc/java/test/Subdiv2DTest.java +++ b/modules/geometry/misc/java/test/Subdiv2DTest.java @@ -1,9 +1,9 @@ -package org.opencv.test.cv3d; +package org.opencv.test.geometry; import org.opencv.core.MatOfFloat6; import org.opencv.core.Point; import org.opencv.core.Rect; -import org.opencv.cv3d.Subdiv2D; +import org.opencv.geometry.Subdiv2D; import org.opencv.test.OpenCVTestCase; public class Subdiv2DTest extends OpenCVTestCase { diff --git a/modules/geometry/misc/js/gen_dict.json b/modules/geometry/misc/js/gen_dict.json new file mode 100644 index 0000000000..690f6c9678 --- /dev/null +++ b/modules/geometry/misc/js/gen_dict.json @@ -0,0 +1,37 @@ +{ + "whitelist": + { + "": [ + "findHomography", + "drawFrameAxes", + "estimateAffine2D", + "getDefaultNewCameraMatrix", + "initUndistortRectifyMap", + "Rodrigues", + "solvePnP", + "solvePnPRansac", + "solvePnPRefineLM", + "projectPoints", + "undistort", + "fisheye_initUndistortRectifyMap", + "fisheye_projectPoints", + "approxPolyDP", + "approxPolyN", + "boundingRect", + "minAreaRect", + "minEnclosingCircle", + "minEnclosingTriangle", + "matchShapes", + "convexHull", + "convexityDefects", + "isContourConvex", + "intersectConvexConvex", + "fitEllipse", + "fitEllipseAMS", + "fitEllipseDirect", + "fitLine", + "pointPolygonTest" + ], + "UsacParams": ["UsacParams"] + } +} diff --git a/modules/3d/misc/objc/gen_dict.json b/modules/geometry/misc/objc/gen_dict.json similarity index 100% rename from modules/3d/misc/objc/gen_dict.json rename to modules/geometry/misc/objc/gen_dict.json diff --git a/modules/3d/misc/objc/test/Cv3dTest.swift b/modules/geometry/misc/objc/test/Cv3dTest.swift similarity index 100% rename from modules/3d/misc/objc/test/Cv3dTest.swift rename to modules/geometry/misc/objc/test/Cv3dTest.swift diff --git a/modules/3d/misc/objc/test/Subdiv2DTest.swift b/modules/geometry/misc/objc/test/Subdiv2DTest.swift similarity index 100% rename from modules/3d/misc/objc/test/Subdiv2DTest.swift rename to modules/geometry/misc/objc/test/Subdiv2DTest.swift diff --git a/modules/3d/misc/python/test/test_iomesh.py b/modules/geometry/misc/python/test/test_iomesh.py similarity index 100% rename from modules/3d/misc/python/test/test_iomesh.py rename to modules/geometry/misc/python/test/test_iomesh.py diff --git a/modules/3d/misc/python/test/test_octree.py b/modules/geometry/misc/python/test/test_octree.py similarity index 100% rename from modules/3d/misc/python/test/test_octree.py rename to modules/geometry/misc/python/test/test_octree.py diff --git a/modules/3d/misc/python/test/test_odometry.py b/modules/geometry/misc/python/test/test_odometry.py similarity index 100% rename from modules/3d/misc/python/test/test_odometry.py rename to modules/geometry/misc/python/test/test_odometry.py diff --git a/modules/3d/misc/python/test/test_raster.py b/modules/geometry/misc/python/test/test_raster.py similarity index 100% rename from modules/3d/misc/python/test/test_raster.py rename to modules/geometry/misc/python/test/test_raster.py diff --git a/modules/3d/misc/python/test/test_rgbd.py b/modules/geometry/misc/python/test/test_rgbd.py similarity index 100% rename from modules/3d/misc/python/test/test_rgbd.py rename to modules/geometry/misc/python/test/test_rgbd.py diff --git a/modules/3d/misc/python/test/test_solvepnp.py b/modules/geometry/misc/python/test/test_solvepnp.py similarity index 100% rename from modules/3d/misc/python/test/test_solvepnp.py rename to modules/geometry/misc/python/test/test_solvepnp.py diff --git a/modules/3d/misc/python/test/test_volume.py b/modules/geometry/misc/python/test/test_volume.py similarity index 100% rename from modules/3d/misc/python/test/test_volume.py rename to modules/geometry/misc/python/test/test_volume.py diff --git a/modules/3d/perf/perf_2d.cpp b/modules/geometry/perf/perf_2d.cpp similarity index 100% rename from modules/3d/perf/perf_2d.cpp rename to modules/geometry/perf/perf_2d.cpp diff --git a/modules/3d/perf/perf_affine2d.cpp b/modules/geometry/perf/perf_affine2d.cpp similarity index 100% rename from modules/3d/perf/perf_affine2d.cpp rename to modules/geometry/perf/perf_affine2d.cpp diff --git a/modules/3d/perf/perf_main.cpp b/modules/geometry/perf/perf_main.cpp similarity index 100% rename from modules/3d/perf/perf_main.cpp rename to modules/geometry/perf/perf_main.cpp diff --git a/modules/3d/perf/perf_pnp.cpp b/modules/geometry/perf/perf_pnp.cpp similarity index 100% rename from modules/3d/perf/perf_pnp.cpp rename to modules/geometry/perf/perf_pnp.cpp diff --git a/modules/3d/perf/perf_precomp.hpp b/modules/geometry/perf/perf_precomp.hpp similarity index 91% rename from modules/3d/perf/perf_precomp.hpp rename to modules/geometry/perf/perf_precomp.hpp index 0a02bd551c..26a6605469 100644 --- a/modules/3d/perf/perf_precomp.hpp +++ b/modules/geometry/perf/perf_precomp.hpp @@ -5,7 +5,7 @@ #define __OPENCV_PERF_PRECOMP_HPP__ #include "opencv2/ts.hpp" -#include "opencv2/3d.hpp" +#include "opencv2/geometry.hpp" #ifdef HAVE_OPENCL #include diff --git a/modules/3d/perf/perf_rendering.cpp b/modules/geometry/perf/perf_rendering.cpp similarity index 100% rename from modules/3d/perf/perf_rendering.cpp rename to modules/geometry/perf/perf_rendering.cpp diff --git a/modules/3d/perf/perf_tsdf.cpp b/modules/geometry/perf/perf_tsdf.cpp similarity index 100% rename from modules/3d/perf/perf_tsdf.cpp rename to modules/geometry/perf/perf_tsdf.cpp diff --git a/modules/3d/perf/perf_undistort.cpp b/modules/geometry/perf/perf_undistort.cpp similarity index 100% rename from modules/3d/perf/perf_undistort.cpp rename to modules/geometry/perf/perf_undistort.cpp diff --git a/modules/3d/samples/odometry_evaluation.cpp b/modules/geometry/samples/odometry_evaluation.cpp similarity index 99% rename from modules/3d/samples/odometry_evaluation.cpp rename to modules/geometry/samples/odometry_evaluation.cpp index bdf46eb95d..cb35af71bf 100644 --- a/modules/3d/samples/odometry_evaluation.cpp +++ b/modules/geometry/samples/odometry_evaluation.cpp @@ -2,10 +2,9 @@ // It is subject to the license terms in the LICENSE file found in the top-level directory // of this distribution and at http://opencv.org/license.html -#include +#include #include -#include #include #include #include diff --git a/modules/3d/src/ap3p.cpp b/modules/geometry/src/ap3p.cpp similarity index 100% rename from modules/3d/src/ap3p.cpp rename to modules/geometry/src/ap3p.cpp diff --git a/modules/3d/src/ap3p.h b/modules/geometry/src/ap3p.h similarity index 100% rename from modules/3d/src/ap3p.h rename to modules/geometry/src/ap3p.h diff --git a/modules/3d/src/approx.cpp b/modules/geometry/src/approx.cpp similarity index 100% rename from modules/3d/src/approx.cpp rename to modules/geometry/src/approx.cpp diff --git a/modules/3d/src/calibration_base.cpp b/modules/geometry/src/calibration_base.cpp similarity index 100% rename from modules/3d/src/calibration_base.cpp rename to modules/geometry/src/calibration_base.cpp diff --git a/modules/3d/src/convhull.cpp b/modules/geometry/src/convhull.cpp similarity index 100% rename from modules/3d/src/convhull.cpp rename to modules/geometry/src/convhull.cpp diff --git a/modules/3d/src/distortion_model.hpp b/modules/geometry/src/distortion_model.hpp similarity index 100% rename from modules/3d/src/distortion_model.hpp rename to modules/geometry/src/distortion_model.hpp diff --git a/modules/3d/src/epnp.cpp b/modules/geometry/src/epnp.cpp similarity index 100% rename from modules/3d/src/epnp.cpp rename to modules/geometry/src/epnp.cpp diff --git a/modules/3d/src/epnp.h b/modules/geometry/src/epnp.h similarity index 100% rename from modules/3d/src/epnp.h rename to modules/geometry/src/epnp.h diff --git a/modules/3d/src/fisheye.cpp b/modules/geometry/src/fisheye.cpp similarity index 100% rename from modules/3d/src/fisheye.cpp rename to modules/geometry/src/fisheye.cpp diff --git a/modules/3d/src/five-point.cpp b/modules/geometry/src/five-point.cpp similarity index 100% rename from modules/3d/src/five-point.cpp rename to modules/geometry/src/five-point.cpp diff --git a/modules/3d/src/fundam.cpp b/modules/geometry/src/fundam.cpp similarity index 100% rename from modules/3d/src/fundam.cpp rename to modules/geometry/src/fundam.cpp diff --git a/modules/3d/src/geometry.cpp b/modules/geometry/src/geometry.cpp similarity index 100% rename from modules/3d/src/geometry.cpp rename to modules/geometry/src/geometry.cpp diff --git a/modules/3d/src/hal_replacement.hpp b/modules/geometry/src/hal_replacement.hpp similarity index 100% rename from modules/3d/src/hal_replacement.hpp rename to modules/geometry/src/hal_replacement.hpp diff --git a/modules/3d/src/homography_decomp.cpp b/modules/geometry/src/homography_decomp.cpp similarity index 100% rename from modules/3d/src/homography_decomp.cpp rename to modules/geometry/src/homography_decomp.cpp diff --git a/modules/3d/src/intersection.cpp b/modules/geometry/src/intersection.cpp similarity index 100% rename from modules/3d/src/intersection.cpp rename to modules/geometry/src/intersection.cpp diff --git a/modules/3d/src/ippe.cpp b/modules/geometry/src/ippe.cpp similarity index 100% rename from modules/3d/src/ippe.cpp rename to modules/geometry/src/ippe.cpp diff --git a/modules/3d/src/ippe.hpp b/modules/geometry/src/ippe.hpp similarity index 100% rename from modules/3d/src/ippe.hpp rename to modules/geometry/src/ippe.hpp diff --git a/modules/3d/src/levmarq.cpp b/modules/geometry/src/levmarq.cpp similarity index 100% rename from modules/3d/src/levmarq.cpp rename to modules/geometry/src/levmarq.cpp diff --git a/modules/3d/src/linefit.cpp b/modules/geometry/src/linefit.cpp similarity index 100% rename from modules/3d/src/linefit.cpp rename to modules/geometry/src/linefit.cpp diff --git a/modules/3d/src/lsd.cpp b/modules/geometry/src/lsd.cpp similarity index 100% rename from modules/3d/src/lsd.cpp rename to modules/geometry/src/lsd.cpp diff --git a/modules/3d/src/main.cpp b/modules/geometry/src/main.cpp similarity index 100% rename from modules/3d/src/main.cpp rename to modules/geometry/src/main.cpp diff --git a/modules/3d/src/matchcontours.cpp b/modules/geometry/src/matchcontours.cpp similarity index 100% rename from modules/3d/src/matchcontours.cpp rename to modules/geometry/src/matchcontours.cpp diff --git a/modules/3d/src/min_enclosing_convex_polygon.cpp b/modules/geometry/src/min_enclosing_convex_polygon.cpp similarity index 100% rename from modules/3d/src/min_enclosing_convex_polygon.cpp rename to modules/geometry/src/min_enclosing_convex_polygon.cpp diff --git a/modules/3d/src/min_enclosing_triangle.cpp b/modules/geometry/src/min_enclosing_triangle.cpp similarity index 100% rename from modules/3d/src/min_enclosing_triangle.cpp rename to modules/geometry/src/min_enclosing_triangle.cpp diff --git a/modules/3d/src/mst.cpp b/modules/geometry/src/mst.cpp similarity index 99% rename from modules/3d/src/mst.cpp rename to modules/geometry/src/mst.cpp index 989db09ab5..27154c23a6 100644 --- a/modules/3d/src/mst.cpp +++ b/modules/geometry/src/mst.cpp @@ -3,7 +3,7 @@ // of this distribution and at http://opencv.org/license.html #include "precomp.hpp" -#include +#include #include #include diff --git a/modules/3d/src/octree.cpp b/modules/geometry/src/octree.cpp similarity index 99% rename from modules/3d/src/octree.cpp rename to modules/geometry/src/octree.cpp index a1272c8743..8ad57f7d3f 100644 --- a/modules/3d/src/octree.cpp +++ b/modules/geometry/src/octree.cpp @@ -4,7 +4,7 @@ #include "precomp.hpp" #include "octree.hpp" -#include "opencv2/3d.hpp" +#include "opencv2/geometry/3d.hpp" namespace cv{ @@ -692,4 +692,4 @@ void Octree::KNNSearch(const Point3f &query, const int K, OutputArray points, Ou Mat(outSqDists).copyTo(squareDists); } } -} \ No newline at end of file +} diff --git a/modules/3d/src/octree.hpp b/modules/geometry/src/octree.hpp similarity index 100% rename from modules/3d/src/octree.hpp rename to modules/geometry/src/octree.hpp diff --git a/modules/3d/src/opencl/hash_tsdf.cl b/modules/geometry/src/opencl/hash_tsdf.cl similarity index 100% rename from modules/3d/src/opencl/hash_tsdf.cl rename to modules/geometry/src/opencl/hash_tsdf.cl diff --git a/modules/3d/src/opencl/icp.cl b/modules/geometry/src/opencl/icp.cl similarity index 100% rename from modules/3d/src/opencl/icp.cl rename to modules/geometry/src/opencl/icp.cl diff --git a/modules/3d/src/opencl/kinfu_frame.cl b/modules/geometry/src/opencl/kinfu_frame.cl similarity index 100% rename from modules/3d/src/opencl/kinfu_frame.cl rename to modules/geometry/src/opencl/kinfu_frame.cl diff --git a/modules/3d/src/opencl/stereobm.cl b/modules/geometry/src/opencl/stereobm.cl similarity index 100% rename from modules/3d/src/opencl/stereobm.cl rename to modules/geometry/src/opencl/stereobm.cl diff --git a/modules/3d/src/opencl/tsdf.cl b/modules/geometry/src/opencl/tsdf.cl similarity index 100% rename from modules/3d/src/opencl/tsdf.cl rename to modules/geometry/src/opencl/tsdf.cl diff --git a/modules/3d/src/p3p.cpp b/modules/geometry/src/p3p.cpp similarity index 100% rename from modules/3d/src/p3p.cpp rename to modules/geometry/src/p3p.cpp diff --git a/modules/3d/src/p3p.h b/modules/geometry/src/p3p.h similarity index 100% rename from modules/3d/src/p3p.h rename to modules/geometry/src/p3p.h diff --git a/modules/3d/src/pcc.h b/modules/geometry/src/pcc.h similarity index 98% rename from modules/3d/src/pcc.h rename to modules/geometry/src/pcc.h index 778ad59fdb..b1393acbf8 100644 --- a/modules/3d/src/pcc.h +++ b/modules/geometry/src/pcc.h @@ -12,7 +12,7 @@ #include #include "opencv2/core.hpp" #include "octree.hpp" -#include "opencv2/3d.hpp" +#include "opencv2/geometry/3d.hpp" namespace cv { diff --git a/modules/3d/src/pointcloud/io_base.cpp b/modules/geometry/src/pointcloud/io_base.cpp similarity index 100% rename from modules/3d/src/pointcloud/io_base.cpp rename to modules/geometry/src/pointcloud/io_base.cpp diff --git a/modules/3d/src/pointcloud/io_base.hpp b/modules/geometry/src/pointcloud/io_base.hpp similarity index 100% rename from modules/3d/src/pointcloud/io_base.hpp rename to modules/geometry/src/pointcloud/io_base.hpp diff --git a/modules/3d/src/pointcloud/io_obj.cpp b/modules/geometry/src/pointcloud/io_obj.cpp similarity index 100% rename from modules/3d/src/pointcloud/io_obj.cpp rename to modules/geometry/src/pointcloud/io_obj.cpp diff --git a/modules/3d/src/pointcloud/io_obj.hpp b/modules/geometry/src/pointcloud/io_obj.hpp similarity index 100% rename from modules/3d/src/pointcloud/io_obj.hpp rename to modules/geometry/src/pointcloud/io_obj.hpp diff --git a/modules/3d/src/pointcloud/io_ply.cpp b/modules/geometry/src/pointcloud/io_ply.cpp similarity index 100% rename from modules/3d/src/pointcloud/io_ply.cpp rename to modules/geometry/src/pointcloud/io_ply.cpp diff --git a/modules/3d/src/pointcloud/io_ply.hpp b/modules/geometry/src/pointcloud/io_ply.hpp similarity index 100% rename from modules/3d/src/pointcloud/io_ply.hpp rename to modules/geometry/src/pointcloud/io_ply.hpp diff --git a/modules/3d/src/pointcloud/load_point_cloud.cpp b/modules/geometry/src/pointcloud/load_point_cloud.cpp similarity index 100% rename from modules/3d/src/pointcloud/load_point_cloud.cpp rename to modules/geometry/src/pointcloud/load_point_cloud.cpp diff --git a/modules/3d/src/pointcloud/utils.cpp b/modules/geometry/src/pointcloud/utils.cpp similarity index 100% rename from modules/3d/src/pointcloud/utils.cpp rename to modules/geometry/src/pointcloud/utils.cpp diff --git a/modules/3d/src/pointcloud/utils.hpp b/modules/geometry/src/pointcloud/utils.hpp similarity index 100% rename from modules/3d/src/pointcloud/utils.hpp rename to modules/geometry/src/pointcloud/utils.hpp diff --git a/modules/3d/src/polynom_solver.cpp b/modules/geometry/src/polynom_solver.cpp similarity index 100% rename from modules/3d/src/polynom_solver.cpp rename to modules/geometry/src/polynom_solver.cpp diff --git a/modules/3d/src/polynom_solver.h b/modules/geometry/src/polynom_solver.h similarity index 100% rename from modules/3d/src/polynom_solver.h rename to modules/geometry/src/polynom_solver.h diff --git a/modules/3d/src/precomp.hpp b/modules/geometry/src/precomp.hpp similarity index 97% rename from modules/3d/src/precomp.hpp rename to modules/geometry/src/precomp.hpp index 56701d0191..a57bebfd72 100755 --- a/modules/3d/src/precomp.hpp +++ b/modules/geometry/src/precomp.hpp @@ -62,14 +62,14 @@ #include "opencv2/core/utils/logger.hpp" #include "opencv2/core/utils/trace.hpp" -#include "opencv2/3d.hpp" +#include "opencv2/geometry.hpp" #include "opencv2/imgproc.hpp" #include "opencv2/core/ocl.hpp" #include "opencv2/core/hal/intrin.hpp" -#include "opencv2/3d/detail/optimizer.hpp" -#include "opencv2/3d/detail/kinfu_frame.hpp" +#include "opencv2/geometry/detail/optimizer.hpp" +#include "opencv2/geometry/detail/kinfu_frame.hpp" #include #include diff --git a/modules/3d/src/ptcloud/normal_estimation.cpp b/modules/geometry/src/ptcloud/normal_estimation.cpp similarity index 100% rename from modules/3d/src/ptcloud/normal_estimation.cpp rename to modules/geometry/src/ptcloud/normal_estimation.cpp diff --git a/modules/3d/src/ptcloud/ptcloud_utils.cpp b/modules/geometry/src/ptcloud/ptcloud_utils.cpp similarity index 100% rename from modules/3d/src/ptcloud/ptcloud_utils.cpp rename to modules/geometry/src/ptcloud/ptcloud_utils.cpp diff --git a/modules/3d/src/ptcloud/ptcloud_utils.hpp b/modules/geometry/src/ptcloud/ptcloud_utils.hpp similarity index 100% rename from modules/3d/src/ptcloud/ptcloud_utils.hpp rename to modules/geometry/src/ptcloud/ptcloud_utils.hpp diff --git a/modules/3d/src/ptcloud/ptcloud_wrapper.hpp b/modules/geometry/src/ptcloud/ptcloud_wrapper.hpp similarity index 100% rename from modules/3d/src/ptcloud/ptcloud_wrapper.hpp rename to modules/geometry/src/ptcloud/ptcloud_wrapper.hpp diff --git a/modules/3d/src/ptcloud/region_growing_3d.cpp b/modules/geometry/src/ptcloud/region_growing_3d.cpp similarity index 100% rename from modules/3d/src/ptcloud/region_growing_3d.cpp rename to modules/geometry/src/ptcloud/region_growing_3d.cpp diff --git a/modules/3d/src/ptcloud/region_growing_3d.hpp b/modules/geometry/src/ptcloud/region_growing_3d.hpp similarity index 99% rename from modules/3d/src/ptcloud/region_growing_3d.hpp rename to modules/geometry/src/ptcloud/region_growing_3d.hpp index d35455e1d2..23bffac7d2 100644 --- a/modules/3d/src/ptcloud/region_growing_3d.hpp +++ b/modules/geometry/src/ptcloud/region_growing_3d.hpp @@ -7,7 +7,7 @@ #ifndef OPENCV_REGION_ROWING_3D_HPP #define OPENCV_REGION_ROWING_3D_HPP -#include "opencv2/3d/ptcloud.hpp" +#include "opencv2/geometry/ptcloud.hpp" #include "ptcloud_utils.hpp" namespace cv { diff --git a/modules/3d/src/ptcloud/sac_segmentation.cpp b/modules/geometry/src/ptcloud/sac_segmentation.cpp similarity index 99% rename from modules/3d/src/ptcloud/sac_segmentation.cpp rename to modules/geometry/src/ptcloud/sac_segmentation.cpp index 800e2759ff..21294fd4d8 100644 --- a/modules/3d/src/ptcloud/sac_segmentation.cpp +++ b/modules/geometry/src/ptcloud/sac_segmentation.cpp @@ -7,7 +7,7 @@ #include "../precomp.hpp" #include "sac_segmentation.hpp" -#include "opencv2/3d/ptcloud.hpp" +#include "opencv2/geometry/ptcloud.hpp" #include "ptcloud_utils.hpp" #include "../usac.hpp" @@ -269,4 +269,4 @@ SACSegmentationImpl::segment(InputArray input_pts, OutputArray labels, } // } // _3d:: -} // cv:: \ No newline at end of file +} // cv:: diff --git a/modules/3d/src/ptcloud/sac_segmentation.hpp b/modules/geometry/src/ptcloud/sac_segmentation.hpp similarity index 99% rename from modules/3d/src/ptcloud/sac_segmentation.hpp rename to modules/geometry/src/ptcloud/sac_segmentation.hpp index 7fe3b1ba27..49d36c525f 100644 --- a/modules/3d/src/ptcloud/sac_segmentation.hpp +++ b/modules/geometry/src/ptcloud/sac_segmentation.hpp @@ -7,7 +7,7 @@ #ifndef OPENCV_3D_SAC_SEGMENTATION_HPP #define OPENCV_3D_SAC_SEGMENTATION_HPP -#include "opencv2/3d/ptcloud.hpp" +#include "opencv2/geometry/ptcloud.hpp" namespace cv { diff --git a/modules/3d/src/ptcloud/sampling.cpp b/modules/geometry/src/ptcloud/sampling.cpp similarity index 99% rename from modules/3d/src/ptcloud/sampling.cpp rename to modules/geometry/src/ptcloud/sampling.cpp index 6920301a2c..8f48611e2b 100644 --- a/modules/3d/src/ptcloud/sampling.cpp +++ b/modules/geometry/src/ptcloud/sampling.cpp @@ -7,7 +7,7 @@ #include "../precomp.hpp" -#include "opencv2/3d/ptcloud.hpp" +#include "opencv2/geometry/ptcloud.hpp" #include "ptcloud_utils.hpp" #include diff --git a/modules/3d/src/ptsetreg.cpp b/modules/geometry/src/ptsetreg.cpp similarity index 100% rename from modules/3d/src/ptsetreg.cpp rename to modules/geometry/src/ptsetreg.cpp diff --git a/modules/3d/src/rendering.cpp b/modules/geometry/src/rendering.cpp similarity index 100% rename from modules/3d/src/rendering.cpp rename to modules/geometry/src/rendering.cpp diff --git a/modules/3d/src/rgbd/color_tsdf_functions.cpp b/modules/geometry/src/rgbd/color_tsdf_functions.cpp similarity index 99% rename from modules/3d/src/rgbd/color_tsdf_functions.cpp rename to modules/geometry/src/rgbd/color_tsdf_functions.cpp index 1c4cb2aff1..09fe339a95 100644 --- a/modules/3d/src/rgbd/color_tsdf_functions.cpp +++ b/modules/geometry/src/rgbd/color_tsdf_functions.cpp @@ -7,7 +7,7 @@ #include "../precomp.hpp" #include "color_tsdf_functions.hpp" -#include "opencl_kernels_3d.hpp" +#include "opencl_kernels_geometry.hpp" namespace cv { diff --git a/modules/3d/src/rgbd/color_tsdf_functions.hpp b/modules/geometry/src/rgbd/color_tsdf_functions.hpp similarity index 100% rename from modules/3d/src/rgbd/color_tsdf_functions.hpp rename to modules/geometry/src/rgbd/color_tsdf_functions.hpp diff --git a/modules/3d/src/rgbd/depth_registration.cpp b/modules/geometry/src/rgbd/depth_registration.cpp similarity index 100% rename from modules/3d/src/rgbd/depth_registration.cpp rename to modules/geometry/src/rgbd/depth_registration.cpp diff --git a/modules/3d/src/rgbd/depth_to_3d.cpp b/modules/geometry/src/rgbd/depth_to_3d.cpp similarity index 100% rename from modules/3d/src/rgbd/depth_to_3d.cpp rename to modules/geometry/src/rgbd/depth_to_3d.cpp diff --git a/modules/3d/src/rgbd/depth_to_3d.hpp b/modules/geometry/src/rgbd/depth_to_3d.hpp similarity index 100% rename from modules/3d/src/rgbd/depth_to_3d.hpp rename to modules/geometry/src/rgbd/depth_to_3d.hpp diff --git a/modules/3d/src/rgbd/hash_tsdf_functions.cpp b/modules/geometry/src/rgbd/hash_tsdf_functions.cpp similarity index 99% rename from modules/3d/src/rgbd/hash_tsdf_functions.cpp rename to modules/geometry/src/rgbd/hash_tsdf_functions.cpp index 15ad3197cc..430c36b9d7 100644 --- a/modules/3d/src/rgbd/hash_tsdf_functions.cpp +++ b/modules/geometry/src/rgbd/hash_tsdf_functions.cpp @@ -7,7 +7,7 @@ #include "../precomp.hpp" #include "hash_tsdf_functions.hpp" -#include "opencl_kernels_3d.hpp" +#include "opencl_kernels_geometry.hpp" namespace cv { @@ -445,7 +445,7 @@ void markActive( //! Mark volumes in the camera frustum as active String errorStr; String name = "markActive"; - ocl::ProgramSource source = ocl::_3d::hash_tsdf_oclsrc; + ocl::ProgramSource source = ocl::geometry::hash_tsdf_oclsrc; String options = "-cl-mad-enable"; ocl::Kernel k; k.create(name.c_str(), source, options, &errorStr); @@ -567,7 +567,7 @@ void ocl_integrateHashTsdfVolumeUnit( //! Integrate the correct volumeUnits String errorStr; String name = "integrateAllVolumeUnits"; - ocl::ProgramSource source = ocl::_3d::hash_tsdf_oclsrc; + ocl::ProgramSource source = ocl::geometry::hash_tsdf_oclsrc; String options = "-cl-mad-enable"; ocl::Kernel k; k.create(name.c_str(), source, options, &errorStr); @@ -1140,7 +1140,7 @@ void ocl_raycastHashTsdfVolumeUnit( String errorStr; String name = "raycast"; - ocl::ProgramSource source = ocl::_3d::hash_tsdf_oclsrc; + ocl::ProgramSource source = ocl::geometry::hash_tsdf_oclsrc; String options = "-cl-mad-enable"; ocl::Kernel k; k.create(name.c_str(), source, options, &errorStr); diff --git a/modules/3d/src/rgbd/hash_tsdf_functions.hpp b/modules/geometry/src/rgbd/hash_tsdf_functions.hpp similarity index 100% rename from modules/3d/src/rgbd/hash_tsdf_functions.hpp rename to modules/geometry/src/rgbd/hash_tsdf_functions.hpp diff --git a/modules/3d/src/rgbd/kinfu_frame.cpp b/modules/geometry/src/rgbd/kinfu_frame.cpp similarity index 98% rename from modules/3d/src/rgbd/kinfu_frame.cpp rename to modules/geometry/src/rgbd/kinfu_frame.cpp index 8c9f7418d1..e48cb9e6e6 100644 --- a/modules/3d/src/rgbd/kinfu_frame.cpp +++ b/modules/geometry/src/rgbd/kinfu_frame.cpp @@ -7,7 +7,7 @@ #include "../precomp.hpp" #include "utils.hpp" -#include "opencl_kernels_3d.hpp" +#include "opencl_kernels_geometry.hpp" namespace cv { @@ -383,7 +383,7 @@ bool computePointsNormalsGpu(const Intr intr, float depthFactor, const UMat& dep cv::String errorStr; cv::String name = "computePointsNormals"; - ocl::ProgramSource source = ocl::_3d::kinfu_frame_oclsrc; + ocl::ProgramSource source = ocl::geometry::kinfu_frame_oclsrc; cv::String options = "-cl-mad-enable"; ocl::Kernel k; k.create(name.c_str(), source, options, &errorStr); @@ -416,7 +416,7 @@ bool pyrDownBilateralGpu(const UMat& depth, UMat& depthDown, float sigma) cv::String errorStr; cv::String name = "pyrDownBilateral"; - ocl::ProgramSource source = ocl::_3d::kinfu_frame_oclsrc; + ocl::ProgramSource source = ocl::geometry::kinfu_frame_oclsrc; cv::String options = "-cl-mad-enable"; ocl::Kernel k; k.create(name.c_str(), source, options, &errorStr); @@ -450,7 +450,7 @@ bool customBilateralFilterGpu(const UMat src /* udepth */, UMat& dst /* smooth * cv::String errorStr; cv::String name = "customBilateral"; - ocl::ProgramSource source = ocl::_3d::kinfu_frame_oclsrc; + ocl::ProgramSource source = ocl::geometry::kinfu_frame_oclsrc; cv::String options = "-cl-mad-enable"; ocl::Kernel k; k.create(name.c_str(), source, options, &errorStr); @@ -479,7 +479,7 @@ bool pyrDownPointsNormalsGpu(const UMat p, const UMat n, UMat &pdown, UMat &ndow cv::String errorStr; cv::String name = "pyrDownPointsNormals"; - ocl::ProgramSource source = ocl::_3d::kinfu_frame_oclsrc; + ocl::ProgramSource source = ocl::geometry::kinfu_frame_oclsrc; cv::String options = "-cl-mad-enable"; ocl::Kernel k; k.create(name.c_str(), source, options, &errorStr); @@ -510,7 +510,7 @@ static bool ocl_renderPointsNormals(const UMat points, const UMat normals, cv::String errorStr; cv::String name = "render"; - ocl::ProgramSource source = ocl::_3d::kinfu_frame_oclsrc; + ocl::ProgramSource source = ocl::geometry::kinfu_frame_oclsrc; cv::String options = "-cl-mad-enable"; ocl::Kernel k; k.create(name.c_str(), source, options, &errorStr); diff --git a/modules/3d/src/rgbd/normal.cpp b/modules/geometry/src/rgbd/normal.cpp similarity index 100% rename from modules/3d/src/rgbd/normal.cpp rename to modules/geometry/src/rgbd/normal.cpp diff --git a/modules/3d/src/rgbd/odometry.cpp b/modules/geometry/src/rgbd/odometry.cpp similarity index 99% rename from modules/3d/src/rgbd/odometry.cpp rename to modules/geometry/src/rgbd/odometry.cpp index 018227f08f..198e33eab9 100644 --- a/modules/3d/src/rgbd/odometry.cpp +++ b/modules/geometry/src/rgbd/odometry.cpp @@ -4,7 +4,7 @@ #include "../precomp.hpp" #include "utils.hpp" -#include "opencv2/3d/odometry.hpp" +#include "opencv2/geometry/odometry.hpp" #include "odometry_functions.hpp" namespace cv diff --git a/modules/3d/src/rgbd/odometry_frame_impl.cpp b/modules/geometry/src/rgbd/odometry_frame_impl.cpp similarity index 100% rename from modules/3d/src/rgbd/odometry_frame_impl.cpp rename to modules/geometry/src/rgbd/odometry_frame_impl.cpp diff --git a/modules/3d/src/rgbd/odometry_functions.cpp b/modules/geometry/src/rgbd/odometry_functions.cpp similarity index 99% rename from modules/3d/src/rgbd/odometry_functions.cpp rename to modules/geometry/src/rgbd/odometry_functions.cpp index fb8abae2a5..4de5758ff8 100644 --- a/modules/3d/src/rgbd/odometry_functions.cpp +++ b/modules/geometry/src/rgbd/odometry_functions.cpp @@ -5,7 +5,7 @@ #include "odometry_functions.hpp" #include "../precomp.hpp" #include "utils.hpp" -#include "opencl_kernels_3d.hpp" +#include "opencl_kernels_geometry.hpp" #include "opencv2/imgproc.hpp" #include @@ -1394,7 +1394,7 @@ bool ocl_calcICPLsmMatricesFast(Matx33f cameraMatrix, const UMat& oldPts, const UMat groupedSumBuffer; cv::String errorStr; String name = "getAb"; - ocl::ProgramSource source = ocl::_3d::icp_oclsrc; + ocl::ProgramSource source = ocl::geometry::icp_oclsrc; cv::String options = "-cl-mad-enable"; ocl::Kernel k; k.create(name.c_str(), source, options, &errorStr); diff --git a/modules/3d/src/rgbd/odometry_functions.hpp b/modules/geometry/src/rgbd/odometry_functions.hpp similarity index 100% rename from modules/3d/src/rgbd/odometry_functions.hpp rename to modules/geometry/src/rgbd/odometry_functions.hpp diff --git a/modules/3d/src/rgbd/odometry_settings_impl.cpp b/modules/geometry/src/rgbd/odometry_settings_impl.cpp similarity index 100% rename from modules/3d/src/rgbd/odometry_settings_impl.cpp rename to modules/geometry/src/rgbd/odometry_settings_impl.cpp diff --git a/modules/3d/src/rgbd/plane.cpp b/modules/geometry/src/rgbd/plane.cpp similarity index 100% rename from modules/3d/src/rgbd/plane.cpp rename to modules/geometry/src/rgbd/plane.cpp diff --git a/modules/3d/src/rgbd/pose_graph.cpp b/modules/geometry/src/rgbd/pose_graph.cpp similarity index 99% rename from modules/3d/src/rgbd/pose_graph.cpp rename to modules/geometry/src/rgbd/pose_graph.cpp index 57932a5c1f..87b08dd61b 100644 --- a/modules/3d/src/rgbd/pose_graph.cpp +++ b/modules/geometry/src/rgbd/pose_graph.cpp @@ -3,8 +3,8 @@ // of this distribution and at http://opencv.org/license.html #include "../precomp.hpp" -#include "opencv2/3d/detail/optimizer.hpp" -#include +#include "opencv2/geometry/detail/optimizer.hpp" +#include #include "sparse_block_matrix.hpp" namespace cv diff --git a/modules/3d/src/rgbd/sparse_block_matrix.hpp b/modules/geometry/src/rgbd/sparse_block_matrix.hpp similarity index 100% rename from modules/3d/src/rgbd/sparse_block_matrix.hpp rename to modules/geometry/src/rgbd/sparse_block_matrix.hpp diff --git a/modules/3d/src/rgbd/tsdf_functions.cpp b/modules/geometry/src/rgbd/tsdf_functions.cpp similarity index 99% rename from modules/3d/src/rgbd/tsdf_functions.cpp rename to modules/geometry/src/rgbd/tsdf_functions.cpp index dec2cf3a47..e3d5a76e16 100644 --- a/modules/3d/src/rgbd/tsdf_functions.cpp +++ b/modules/geometry/src/rgbd/tsdf_functions.cpp @@ -7,7 +7,7 @@ #include "../precomp.hpp" #include "tsdf_functions.hpp" -#include "opencl_kernels_3d.hpp" +#include "opencl_kernels_geometry.hpp" namespace cv { @@ -341,7 +341,7 @@ void ocl_integrateTsdfVolumeUnit(const VolumeSettings& settings, const Matx44f& String errorStr; String name = "integrate"; - ocl::ProgramSource source = ocl::_3d::tsdf_oclsrc; + ocl::ProgramSource source = ocl::geometry::tsdf_oclsrc; String options = "-cl-mad-enable"; ocl::Kernel k; k.create(name.c_str(), source, options, &errorStr); @@ -932,7 +932,7 @@ void ocl_raycastTsdfVolumeUnit(const VolumeSettings& settings, const Matx44f& ca String errorStr; String name = "raycast"; - ocl::ProgramSource source = ocl::_3d::tsdf_oclsrc; + ocl::ProgramSource source = ocl::geometry::tsdf_oclsrc; String options = "-cl-mad-enable"; ocl::Kernel k; k.create(name.c_str(), source, options, &errorStr); @@ -1112,7 +1112,7 @@ void ocl_fetchNormalsFromTsdfVolumeUnit(const VolumeSettings& settings, InputArr String errorStr; String name = "getNormals"; - ocl::ProgramSource source = ocl::_3d::tsdf_oclsrc; + ocl::ProgramSource source = ocl::geometry::tsdf_oclsrc; String options = "-cl-mad-enable"; ocl::Kernel k; k.create(name.c_str(), source, options, &errorStr); @@ -1337,7 +1337,7 @@ void ocl_fetchPointsNormalsFromTsdfVolumeUnit(const VolumeSettings& settings, In ocl::Kernel kscan; String errorStr; - ocl::ProgramSource source = ocl::_3d::tsdf_oclsrc; + ocl::ProgramSource source = ocl::geometry::tsdf_oclsrc; String options = "-cl-mad-enable"; kscan.create("scanSize", source, options, &errorStr); diff --git a/modules/3d/src/rgbd/tsdf_functions.hpp b/modules/geometry/src/rgbd/tsdf_functions.hpp similarity index 100% rename from modules/3d/src/rgbd/tsdf_functions.hpp rename to modules/geometry/src/rgbd/tsdf_functions.hpp diff --git a/modules/3d/src/rgbd/utils.hpp b/modules/geometry/src/rgbd/utils.hpp similarity index 100% rename from modules/3d/src/rgbd/utils.hpp rename to modules/geometry/src/rgbd/utils.hpp diff --git a/modules/3d/src/rgbd/volume_impl.cpp b/modules/geometry/src/rgbd/volume_impl.cpp similarity index 100% rename from modules/3d/src/rgbd/volume_impl.cpp rename to modules/geometry/src/rgbd/volume_impl.cpp diff --git a/modules/3d/src/rgbd/volume_impl.hpp b/modules/geometry/src/rgbd/volume_impl.hpp similarity index 100% rename from modules/3d/src/rgbd/volume_impl.hpp rename to modules/geometry/src/rgbd/volume_impl.hpp diff --git a/modules/3d/src/rgbd/volume_settings_impl.cpp b/modules/geometry/src/rgbd/volume_settings_impl.cpp similarity index 100% rename from modules/3d/src/rgbd/volume_settings_impl.cpp rename to modules/geometry/src/rgbd/volume_settings_impl.cpp diff --git a/modules/3d/src/rho.cpp b/modules/geometry/src/rho.cpp similarity index 100% rename from modules/3d/src/rho.cpp rename to modules/geometry/src/rho.cpp diff --git a/modules/3d/src/rho.h b/modules/geometry/src/rho.h similarity index 100% rename from modules/3d/src/rho.h rename to modules/geometry/src/rho.h diff --git a/modules/3d/src/rotcalipers.cpp b/modules/geometry/src/rotcalipers.cpp similarity index 100% rename from modules/3d/src/rotcalipers.cpp rename to modules/geometry/src/rotcalipers.cpp diff --git a/modules/3d/src/shapedescr.cpp b/modules/geometry/src/shapedescr.cpp similarity index 100% rename from modules/3d/src/shapedescr.cpp rename to modules/geometry/src/shapedescr.cpp diff --git a/modules/3d/src/solvepnp.cpp b/modules/geometry/src/solvepnp.cpp similarity index 100% rename from modules/3d/src/solvepnp.cpp rename to modules/geometry/src/solvepnp.cpp diff --git a/modules/3d/src/sqpnp.cpp b/modules/geometry/src/sqpnp.cpp similarity index 100% rename from modules/3d/src/sqpnp.cpp rename to modules/geometry/src/sqpnp.cpp diff --git a/modules/3d/src/sqpnp.hpp b/modules/geometry/src/sqpnp.hpp similarity index 100% rename from modules/3d/src/sqpnp.hpp rename to modules/geometry/src/sqpnp.hpp diff --git a/modules/3d/src/subdivision2d.cpp b/modules/geometry/src/subdivision2d.cpp similarity index 100% rename from modules/3d/src/subdivision2d.cpp rename to modules/geometry/src/subdivision2d.cpp diff --git a/modules/3d/src/triangulate.cpp b/modules/geometry/src/triangulate.cpp similarity index 100% rename from modules/3d/src/triangulate.cpp rename to modules/geometry/src/triangulate.cpp diff --git a/modules/3d/src/undistort.dispatch.cpp b/modules/geometry/src/undistort.dispatch.cpp similarity index 100% rename from modules/3d/src/undistort.dispatch.cpp rename to modules/geometry/src/undistort.dispatch.cpp diff --git a/modules/3d/src/undistort.simd.hpp b/modules/geometry/src/undistort.simd.hpp similarity index 100% rename from modules/3d/src/undistort.simd.hpp rename to modules/geometry/src/undistort.simd.hpp diff --git a/modules/3d/src/usac.hpp b/modules/geometry/src/usac.hpp similarity index 100% rename from modules/3d/src/usac.hpp rename to modules/geometry/src/usac.hpp diff --git a/modules/3d/src/usac/bundle.cpp b/modules/geometry/src/usac/bundle.cpp similarity index 100% rename from modules/3d/src/usac/bundle.cpp rename to modules/geometry/src/usac/bundle.cpp diff --git a/modules/3d/src/usac/degeneracy.cpp b/modules/geometry/src/usac/degeneracy.cpp similarity index 100% rename from modules/3d/src/usac/degeneracy.cpp rename to modules/geometry/src/usac/degeneracy.cpp diff --git a/modules/3d/src/usac/dls_solver.cpp b/modules/geometry/src/usac/dls_solver.cpp similarity index 100% rename from modules/3d/src/usac/dls_solver.cpp rename to modules/geometry/src/usac/dls_solver.cpp diff --git a/modules/3d/src/usac/essential_solver.cpp b/modules/geometry/src/usac/essential_solver.cpp similarity index 100% rename from modules/3d/src/usac/essential_solver.cpp rename to modules/geometry/src/usac/essential_solver.cpp diff --git a/modules/3d/src/usac/estimator.cpp b/modules/geometry/src/usac/estimator.cpp similarity index 100% rename from modules/3d/src/usac/estimator.cpp rename to modules/geometry/src/usac/estimator.cpp diff --git a/modules/3d/src/usac/fundamental_solver.cpp b/modules/geometry/src/usac/fundamental_solver.cpp similarity index 100% rename from modules/3d/src/usac/fundamental_solver.cpp rename to modules/geometry/src/usac/fundamental_solver.cpp diff --git a/modules/3d/src/usac/gamma_values.cpp b/modules/geometry/src/usac/gamma_values.cpp similarity index 100% rename from modules/3d/src/usac/gamma_values.cpp rename to modules/geometry/src/usac/gamma_values.cpp diff --git a/modules/3d/src/usac/homography_solver.cpp b/modules/geometry/src/usac/homography_solver.cpp similarity index 100% rename from modules/3d/src/usac/homography_solver.cpp rename to modules/geometry/src/usac/homography_solver.cpp diff --git a/modules/3d/src/usac/local_optimization.cpp b/modules/geometry/src/usac/local_optimization.cpp similarity index 100% rename from modules/3d/src/usac/local_optimization.cpp rename to modules/geometry/src/usac/local_optimization.cpp diff --git a/modules/3d/src/usac/plane_solver.cpp b/modules/geometry/src/usac/plane_solver.cpp similarity index 100% rename from modules/3d/src/usac/plane_solver.cpp rename to modules/geometry/src/usac/plane_solver.cpp diff --git a/modules/3d/src/usac/pnp_solver.cpp b/modules/geometry/src/usac/pnp_solver.cpp similarity index 100% rename from modules/3d/src/usac/pnp_solver.cpp rename to modules/geometry/src/usac/pnp_solver.cpp diff --git a/modules/3d/src/usac/quality.cpp b/modules/geometry/src/usac/quality.cpp similarity index 100% rename from modules/3d/src/usac/quality.cpp rename to modules/geometry/src/usac/quality.cpp diff --git a/modules/3d/src/usac/ransac_solvers.cpp b/modules/geometry/src/usac/ransac_solvers.cpp similarity index 100% rename from modules/3d/src/usac/ransac_solvers.cpp rename to modules/geometry/src/usac/ransac_solvers.cpp diff --git a/modules/3d/src/usac/sampler.cpp b/modules/geometry/src/usac/sampler.cpp similarity index 100% rename from modules/3d/src/usac/sampler.cpp rename to modules/geometry/src/usac/sampler.cpp diff --git a/modules/3d/src/usac/sphere_solver.cpp b/modules/geometry/src/usac/sphere_solver.cpp similarity index 100% rename from modules/3d/src/usac/sphere_solver.cpp rename to modules/geometry/src/usac/sphere_solver.cpp diff --git a/modules/3d/src/usac/termination.cpp b/modules/geometry/src/usac/termination.cpp similarity index 100% rename from modules/3d/src/usac/termination.cpp rename to modules/geometry/src/usac/termination.cpp diff --git a/modules/3d/src/usac/utils.cpp b/modules/geometry/src/usac/utils.cpp similarity index 100% rename from modules/3d/src/usac/utils.cpp rename to modules/geometry/src/usac/utils.cpp diff --git a/modules/3d/test/test_affine2d_estimator.cpp b/modules/geometry/test/test_affine2d_estimator.cpp similarity index 100% rename from modules/3d/test/test_affine2d_estimator.cpp rename to modules/geometry/test/test_affine2d_estimator.cpp diff --git a/modules/3d/test/test_affine3.cpp b/modules/geometry/test/test_affine3.cpp similarity index 100% rename from modules/3d/test/test_affine3.cpp rename to modules/geometry/test/test_affine3.cpp diff --git a/modules/3d/test/test_affine3d_estimator.cpp b/modules/geometry/test/test_affine3d_estimator.cpp similarity index 100% rename from modules/3d/test/test_affine3d_estimator.cpp rename to modules/geometry/test/test_affine3d_estimator.cpp diff --git a/modules/3d/test/test_affine_partial2d_estimator.cpp b/modules/geometry/test/test_affine_partial2d_estimator.cpp similarity index 100% rename from modules/3d/test/test_affine_partial2d_estimator.cpp rename to modules/geometry/test/test_affine_partial2d_estimator.cpp diff --git a/modules/3d/test/test_approxpoly.cpp b/modules/geometry/test/test_approxpoly.cpp similarity index 100% rename from modules/3d/test/test_approxpoly.cpp rename to modules/geometry/test/test_approxpoly.cpp diff --git a/modules/3d/test/test_cameras.cpp b/modules/geometry/test/test_cameras.cpp similarity index 99% rename from modules/3d/test/test_cameras.cpp rename to modules/geometry/test/test_cameras.cpp index bfc2ff751c..e7b5c468ff 100644 --- a/modules/3d/test/test_cameras.cpp +++ b/modules/geometry/test/test_cameras.cpp @@ -3,7 +3,7 @@ // of this distribution and at http://opencv.org/license.html. #include "test_precomp.hpp" -#include "opencv2/3d.hpp" +#include "opencv2/geometry.hpp" #include "opencv2/ts/cuda_test.hpp" // EXPECT_MAT_NEAR namespace opencv_test { namespace { diff --git a/modules/3d/test/test_compose_rt.cpp b/modules/geometry/test/test_compose_rt.cpp similarity index 100% rename from modules/3d/test/test_compose_rt.cpp rename to modules/geometry/test/test_compose_rt.cpp diff --git a/modules/3d/test/test_convhull.cpp b/modules/geometry/test/test_convhull.cpp similarity index 100% rename from modules/3d/test/test_convhull.cpp rename to modules/geometry/test/test_convhull.cpp diff --git a/modules/3d/test/test_decompose_projection.cpp b/modules/geometry/test/test_decompose_projection.cpp similarity index 100% rename from modules/3d/test/test_decompose_projection.cpp rename to modules/geometry/test/test_decompose_projection.cpp diff --git a/modules/3d/test/test_filter_homography_decomp.cpp b/modules/geometry/test/test_filter_homography_decomp.cpp similarity index 99% rename from modules/3d/test/test_filter_homography_decomp.cpp rename to modules/geometry/test/test_filter_homography_decomp.cpp index 8fb0572376..9504897a12 100644 --- a/modules/3d/test/test_filter_homography_decomp.cpp +++ b/modules/geometry/test/test_filter_homography_decomp.cpp @@ -41,7 +41,7 @@ //M*/ #include "test_precomp.hpp" -#include "opencv2/3d.hpp" +#include "opencv2/geometry.hpp" namespace opencv_test { namespace { diff --git a/modules/3d/test/test_fisheye.cpp b/modules/geometry/test/test_fisheye.cpp similarity index 100% rename from modules/3d/test/test_fisheye.cpp rename to modules/geometry/test/test_fisheye.cpp diff --git a/modules/3d/test/test_fitellipse.cpp b/modules/geometry/test/test_fitellipse.cpp similarity index 100% rename from modules/3d/test/test_fitellipse.cpp rename to modules/geometry/test/test_fitellipse.cpp diff --git a/modules/3d/test/test_fitellipse_ams.cpp b/modules/geometry/test/test_fitellipse_ams.cpp similarity index 100% rename from modules/3d/test/test_fitellipse_ams.cpp rename to modules/geometry/test/test_fitellipse_ams.cpp diff --git a/modules/3d/test/test_fitellipse_direct.cpp b/modules/geometry/test/test_fitellipse_direct.cpp similarity index 100% rename from modules/3d/test/test_fitellipse_direct.cpp rename to modules/geometry/test/test_fitellipse_direct.cpp diff --git a/modules/3d/test/test_fundam.cpp b/modules/geometry/test/test_fundam.cpp similarity index 100% rename from modules/3d/test/test_fundam.cpp rename to modules/geometry/test/test_fundam.cpp diff --git a/modules/3d/test/test_homography.cpp b/modules/geometry/test/test_homography.cpp similarity index 100% rename from modules/3d/test/test_homography.cpp rename to modules/geometry/test/test_homography.cpp diff --git a/modules/3d/test/test_homography_decomp.cpp b/modules/geometry/test/test_homography_decomp.cpp similarity index 100% rename from modules/3d/test/test_homography_decomp.cpp rename to modules/geometry/test/test_homography_decomp.cpp diff --git a/modules/3d/test/test_intersectconvexconvex.cpp b/modules/geometry/test/test_intersectconvexconvex.cpp similarity index 100% rename from modules/3d/test/test_intersectconvexconvex.cpp rename to modules/geometry/test/test_intersectconvexconvex.cpp diff --git a/modules/3d/test/test_intersection.cpp b/modules/geometry/test/test_intersection.cpp similarity index 100% rename from modules/3d/test/test_intersection.cpp rename to modules/geometry/test/test_intersection.cpp diff --git a/modules/3d/test/test_lsd.cpp b/modules/geometry/test/test_lsd.cpp similarity index 100% rename from modules/3d/test/test_lsd.cpp rename to modules/geometry/test/test_lsd.cpp diff --git a/modules/3d/test/test_main.cpp b/modules/geometry/test/test_main.cpp similarity index 100% rename from modules/3d/test/test_main.cpp rename to modules/geometry/test/test_main.cpp diff --git a/modules/3d/test/test_modelest.cpp b/modules/geometry/test/test_modelest.cpp similarity index 100% rename from modules/3d/test/test_modelest.cpp rename to modules/geometry/test/test_modelest.cpp diff --git a/modules/3d/test/test_mst.cpp b/modules/geometry/test/test_mst.cpp similarity index 99% rename from modules/3d/test/test_mst.cpp rename to modules/geometry/test/test_mst.cpp index 8db42b2395..3b3534d9c2 100644 --- a/modules/3d/test/test_mst.cpp +++ b/modules/geometry/test/test_mst.cpp @@ -3,7 +3,7 @@ // of this distribution and at http://opencv.org/license.html #include "test_precomp.hpp" -#include +#include namespace opencv_test { namespace { diff --git a/modules/3d/test/test_normal.cpp b/modules/geometry/test/test_normal.cpp similarity index 99% rename from modules/3d/test/test_normal.cpp rename to modules/geometry/test/test_normal.cpp index 84175960ac..9fe5d7ff42 100644 --- a/modules/3d/test/test_normal.cpp +++ b/modules/geometry/test/test_normal.cpp @@ -3,7 +3,7 @@ // of this distribution and at http://opencv.org/license.html #include "test_precomp.hpp" -#include +#include #include namespace opencv_test { namespace { diff --git a/modules/3d/test/test_normal_estimation.cpp b/modules/geometry/test/test_normal_estimation.cpp similarity index 100% rename from modules/3d/test/test_normal_estimation.cpp rename to modules/geometry/test/test_normal_estimation.cpp diff --git a/modules/3d/test/test_octree.cpp b/modules/geometry/test/test_octree.cpp similarity index 100% rename from modules/3d/test/test_octree.cpp rename to modules/geometry/test/test_octree.cpp diff --git a/modules/3d/test/test_odometry.cpp b/modules/geometry/test/test_odometry.cpp similarity index 100% rename from modules/3d/test/test_odometry.cpp rename to modules/geometry/test/test_odometry.cpp diff --git a/modules/3d/test/test_pointcloud.cpp b/modules/geometry/test/test_pointcloud.cpp similarity index 100% rename from modules/3d/test/test_pointcloud.cpp rename to modules/geometry/test/test_pointcloud.cpp diff --git a/modules/3d/test/test_pose_graph.cpp b/modules/geometry/test/test_pose_graph.cpp similarity index 99% rename from modules/3d/test/test_pose_graph.cpp rename to modules/geometry/test/test_pose_graph.cpp index a2f345f108..77534eb00e 100644 --- a/modules/3d/test/test_pose_graph.cpp +++ b/modules/geometry/test/test_pose_graph.cpp @@ -3,7 +3,7 @@ // of this distribution and at http://opencv.org/license.html #include "test_precomp.hpp" -#include +#include #include diff --git a/modules/3d/test/test_precomp.hpp b/modules/geometry/test/test_precomp.hpp similarity index 93% rename from modules/3d/test/test_precomp.hpp rename to modules/geometry/test/test_precomp.hpp index 331a259cae..335f65ca73 100644 --- a/modules/3d/test/test_precomp.hpp +++ b/modules/geometry/test/test_precomp.hpp @@ -8,7 +8,7 @@ #include #include "opencv2/ts.hpp" -#include "opencv2/3d.hpp" +#include "opencv2/geometry.hpp" #include #ifdef HAVE_OPENCL diff --git a/modules/3d/test/test_ptcloud_utils.cpp b/modules/geometry/test/test_ptcloud_utils.cpp similarity index 100% rename from modules/3d/test/test_ptcloud_utils.cpp rename to modules/geometry/test/test_ptcloud_utils.cpp diff --git a/modules/3d/test/test_ptcloud_utils.hpp b/modules/geometry/test/test_ptcloud_utils.hpp similarity index 100% rename from modules/3d/test/test_ptcloud_utils.hpp rename to modules/geometry/test/test_ptcloud_utils.hpp diff --git a/modules/3d/test/test_registration.cpp b/modules/geometry/test/test_registration.cpp similarity index 100% rename from modules/3d/test/test_registration.cpp rename to modules/geometry/test/test_registration.cpp diff --git a/modules/3d/test/test_rendering.cpp b/modules/geometry/test/test_rendering.cpp similarity index 100% rename from modules/3d/test/test_rendering.cpp rename to modules/geometry/test/test_rendering.cpp diff --git a/modules/3d/test/test_sac_segmentation.cpp b/modules/geometry/test/test_sac_segmentation.cpp similarity index 100% rename from modules/3d/test/test_sac_segmentation.cpp rename to modules/geometry/test/test_sac_segmentation.cpp diff --git a/modules/3d/test/test_sampling.cpp b/modules/geometry/test/test_sampling.cpp similarity index 100% rename from modules/3d/test/test_sampling.cpp rename to modules/geometry/test/test_sampling.cpp diff --git a/modules/3d/test/test_solvepnp_ransac.cpp b/modules/geometry/test/test_solvepnp_ransac.cpp similarity index 100% rename from modules/3d/test/test_solvepnp_ransac.cpp rename to modules/geometry/test/test_solvepnp_ransac.cpp diff --git a/modules/3d/test/test_subdivision2d.cpp b/modules/geometry/test/test_subdivision2d.cpp similarity index 100% rename from modules/3d/test/test_subdivision2d.cpp rename to modules/geometry/test/test_subdivision2d.cpp diff --git a/modules/3d/test/test_translation2d_estimator.cpp b/modules/geometry/test/test_translation2d_estimator.cpp similarity index 100% rename from modules/3d/test/test_translation2d_estimator.cpp rename to modules/geometry/test/test_translation2d_estimator.cpp diff --git a/modules/3d/test/test_translation3d_estimator.cpp b/modules/geometry/test/test_translation3d_estimator.cpp similarity index 100% rename from modules/3d/test/test_translation3d_estimator.cpp rename to modules/geometry/test/test_translation3d_estimator.cpp diff --git a/modules/3d/test/test_tsdf.cpp b/modules/geometry/test/test_tsdf.cpp similarity index 100% rename from modules/3d/test/test_tsdf.cpp rename to modules/geometry/test/test_tsdf.cpp diff --git a/modules/3d/test/test_undistort.cpp b/modules/geometry/test/test_undistort.cpp similarity index 100% rename from modules/3d/test/test_undistort.cpp rename to modules/geometry/test/test_undistort.cpp diff --git a/modules/3d/test/test_undistort_badarg.cpp b/modules/geometry/test/test_undistort_badarg.cpp similarity index 100% rename from modules/3d/test/test_undistort_badarg.cpp rename to modules/geometry/test/test_undistort_badarg.cpp diff --git a/modules/3d/test/test_undistort_points.cpp b/modules/geometry/test/test_undistort_points.cpp similarity index 100% rename from modules/3d/test/test_undistort_points.cpp rename to modules/geometry/test/test_undistort_points.cpp diff --git a/modules/3d/test/test_usac.cpp b/modules/geometry/test/test_usac.cpp similarity index 100% rename from modules/3d/test/test_usac.cpp rename to modules/geometry/test/test_usac.cpp diff --git a/modules/imgproc/misc/js/gen_dict.json b/modules/imgproc/misc/js/gen_dict.json index c8221a5d55..6b8b7f842c 100644 --- a/modules/imgproc/misc/js/gen_dict.json +++ b/modules/imgproc/misc/js/gen_dict.json @@ -4,14 +4,11 @@ "": [ "adaptiveThreshold", "applyColorMap", - "approxPolyDP", - "approxPolyN", "arcLength", "arrowedLine", "bilateralFilter", "blendLinear", "blur", - "boundingRect", "boxFilter", "calcBackProject", "calcHist", @@ -23,8 +20,6 @@ "connectedComponentsWithStats", "contourArea", "convertMaps", - "convexHull", - "convexityDefects", "cornerHarris", "cornerMinEigenVal", "createCLAHE", @@ -46,10 +41,6 @@ "filter2D", "findContours", "findContoursLinkRuns", - "fitEllipse", - "fitEllipseAMS", - "fitEllipseDirect", - "fitLine", "floodFill", "GaussianBlur", "getAffineTransform", @@ -65,20 +56,13 @@ "HuMoments", "integral", "integral2", - "intersectConvexConvex", "invertAffineTransform", - "isContourConvex", "Laplacian", "line", - "matchShapes", "matchTemplate", "medianBlur", - "minAreaRect", - "minEnclosingCircle", - "minEnclosingTriangle", "moments", "morphologyEx", - "pointPolygonTest", "polylines", "preCornerDetect", "putText", diff --git a/modules/java/test/pure_test/CMakeLists.txt b/modules/java/test/pure_test/CMakeLists.txt index e6904f927f..a9efe85d8b 100644 --- a/modules/java/test/pure_test/CMakeLists.txt +++ b/modules/java/test/pure_test/CMakeLists.txt @@ -1,6 +1,6 @@ if(NOT ANT_EXECUTABLE OR NOT BUILD_opencv_imgcodecs - OR NOT BUILD_opencv_3d) + OR NOT BUILD_opencv_geometry) return() endif() diff --git a/modules/objdetect/CMakeLists.txt b/modules/objdetect/CMakeLists.txt index f16b26d034..6b8c79cdba 100644 --- a/modules/objdetect/CMakeLists.txt +++ b/modules/objdetect/CMakeLists.txt @@ -3,7 +3,7 @@ ocv_define_module(objdetect opencv_core opencv_imgproc opencv_features - opencv_3d + opencv_geometry OPTIONAL opencv_dnn WRAP diff --git a/modules/objdetect/misc/java/test/ObjdetectTest.java b/modules/objdetect/misc/java/test/ObjdetectTest.java index 8d62eed711..36d2e8f703 100644 --- a/modules/objdetect/misc/java/test/ObjdetectTest.java +++ b/modules/objdetect/misc/java/test/ObjdetectTest.java @@ -2,7 +2,6 @@ package org.opencv.test.objdetect; import java.util.ArrayList; -import org.opencv.cv3d.Cv3d; import org.opencv.core.Core; import org.opencv.core.CvType; import org.opencv.core.Mat; diff --git a/modules/objdetect/perf/perf_aruco.cpp b/modules/objdetect/perf/perf_aruco.cpp index c9e15d9e75..5f21d6e2d4 100644 --- a/modules/objdetect/perf/perf_aruco.cpp +++ b/modules/objdetect/perf/perf_aruco.cpp @@ -2,7 +2,7 @@ // It is subject to the license terms in the LICENSE file found in the top-level directory // of this distribution and at http://opencv.org/license.html #include "perf_precomp.hpp" -#include "opencv2/3d.hpp" +#include "opencv2/geometry.hpp" namespace opencv_test { using namespace perf; diff --git a/modules/objdetect/src/aruco/aruco_detector.cpp b/modules/objdetect/src/aruco/aruco_detector.cpp index 069a7efb34..c641f89ab2 100644 --- a/modules/objdetect/src/aruco/aruco_detector.cpp +++ b/modules/objdetect/src/aruco/aruco_detector.cpp @@ -3,7 +3,7 @@ // of this distribution and at http://opencv.org/license.html #include "../precomp.hpp" -#include +#include #include "opencv2/objdetect/aruco_detector.hpp" #include "opencv2/objdetect/aruco_board.hpp" diff --git a/modules/objdetect/src/aruco/charuco_detector.cpp b/modules/objdetect/src/aruco/charuco_detector.cpp index 4f733403db..d0ba8afe12 100644 --- a/modules/objdetect/src/aruco/charuco_detector.cpp +++ b/modules/objdetect/src/aruco/charuco_detector.cpp @@ -4,7 +4,7 @@ #include "../precomp.hpp" -#include +#include #include #include "opencv2/objdetect/charuco_detector.hpp" #include "aruco_utils.hpp" diff --git a/modules/objdetect/src/barcode_detector/bardetect.cpp b/modules/objdetect/src/barcode_detector/bardetect.cpp index 4543c99242..e0fcf7bcd9 100644 --- a/modules/objdetect/src/barcode_detector/bardetect.cpp +++ b/modules/objdetect/src/barcode_detector/bardetect.cpp @@ -5,7 +5,7 @@ #include "../precomp.hpp" #include "bardetect.hpp" -#include "opencv2/3d.hpp" +#include "opencv2/geometry.hpp" namespace cv { namespace barcode { diff --git a/modules/objdetect/src/calibinit.cpp b/modules/objdetect/src/calibinit.cpp index 5a651506ec..83c6b062b7 100644 --- a/modules/objdetect/src/calibinit.cpp +++ b/modules/objdetect/src/calibinit.cpp @@ -71,7 +71,7 @@ #include "precomp.hpp" #include "circlesgrid.hpp" -#include "opencv2/3d.hpp" +#include "opencv2/geometry.hpp" #include "opencv2/flann.hpp" #include diff --git a/modules/objdetect/src/chessboard.cpp b/modules/objdetect/src/chessboard.cpp index 279745c3c4..c382913c80 100644 --- a/modules/objdetect/src/chessboard.cpp +++ b/modules/objdetect/src/chessboard.cpp @@ -4,7 +4,7 @@ #include "precomp.hpp" #include "opencv2/flann.hpp" -#include "opencv2/3d.hpp" +#include "opencv2/geometry.hpp" #include "chessboard.hpp" #include "math.h" diff --git a/modules/objdetect/src/circlesgrid.cpp b/modules/objdetect/src/circlesgrid.cpp index d1a38ad8e6..8088b2c2bd 100644 --- a/modules/objdetect/src/circlesgrid.cpp +++ b/modules/objdetect/src/circlesgrid.cpp @@ -57,7 +57,7 @@ # endif #endif -#include "opencv2/3d.hpp" +#include "opencv2/geometry.hpp" namespace cv { diff --git a/modules/objdetect/src/mcc/precomp.hpp b/modules/objdetect/src/mcc/precomp.hpp index f1671d306f..65d84c2233 100644 --- a/modules/objdetect/src/mcc/precomp.hpp +++ b/modules/objdetect/src/mcc/precomp.hpp @@ -33,7 +33,7 @@ #include #include -#include +#include #ifdef HAVE_OPENCV_DNN #include #endif diff --git a/modules/objdetect/src/precomp.hpp b/modules/objdetect/src/precomp.hpp index 588c19010f..603b2173ad 100644 --- a/modules/objdetect/src/precomp.hpp +++ b/modules/objdetect/src/precomp.hpp @@ -47,7 +47,7 @@ #include "opencv2/objdetect.hpp" #include "opencv2/objdetect/barcode.hpp" #include "opencv2/imgproc.hpp" -#include "opencv2/3d.hpp" +#include "opencv2/geometry.hpp" #include #include "opencv2/core/utility.hpp" diff --git a/modules/objdetect/src/qrcode.cpp b/modules/objdetect/src/qrcode.cpp index f0e5952257..b7d049e35a 100644 --- a/modules/objdetect/src/qrcode.cpp +++ b/modules/objdetect/src/qrcode.cpp @@ -7,7 +7,7 @@ #include "precomp.hpp" #include "opencv2/objdetect.hpp" -#include "opencv2/3d.hpp" +#include "opencv2/geometry.hpp" #include #include "graphical_code_detector_impl.hpp" diff --git a/modules/objdetect/test/test_aruco_utils.hpp b/modules/objdetect/test/test_aruco_utils.hpp index 0120b2c8a3..af9eb4e87b 100644 --- a/modules/objdetect/test/test_aruco_utils.hpp +++ b/modules/objdetect/test/test_aruco_utils.hpp @@ -3,7 +3,7 @@ // of this distribution and at http://opencv.org/license.html. #include "test_precomp.hpp" -#include "opencv2/3d.hpp" +#include "opencv2/geometry.hpp" namespace opencv_test { diff --git a/modules/objdetect/test/test_arucodetection.cpp b/modules/objdetect/test/test_arucodetection.cpp index 28bc132d6f..397367f00a 100644 --- a/modules/objdetect/test/test_arucodetection.cpp +++ b/modules/objdetect/test/test_arucodetection.cpp @@ -4,7 +4,7 @@ #include "test_precomp.hpp" #include "opencv2/objdetect/aruco_detector.hpp" -#include "opencv2/3d.hpp" +#include "opencv2/geometry.hpp" namespace cv { namespace aruco { diff --git a/modules/objdetect/test/test_precomp.hpp b/modules/objdetect/test/test_precomp.hpp index 14b5befda5..1fb1066300 100644 --- a/modules/objdetect/test/test_precomp.hpp +++ b/modules/objdetect/test/test_precomp.hpp @@ -5,7 +5,7 @@ #define __OPENCV_TEST_PRECOMP_HPP__ #include "opencv2/ts.hpp" -#include "opencv2/3d.hpp" +#include "opencv2/geometry.hpp" #include "opencv2/objdetect.hpp" #include diff --git a/modules/photo/CMakeLists.txt b/modules/photo/CMakeLists.txt index 43795fab72..81d1e323c9 100644 --- a/modules/photo/CMakeLists.txt +++ b/modules/photo/CMakeLists.txt @@ -4,7 +4,7 @@ if(HAVE_CUDA) ocv_warnings_disable(CMAKE_CXX_FLAGS -Wundef -Wmissing-declarations -Wshadow) endif() -ocv_define_module(photo opencv_imgproc opencv_3d OPTIONAL opencv_cudaarithm opencv_cudaimgproc WRAP java objc python js) +ocv_define_module(photo opencv_imgproc opencv_geometry OPTIONAL opencv_cudaarithm opencv_cudaimgproc WRAP java objc python js) if(HAVE_CUDA AND ENABLE_CUDA_FIRST_CLASS_LANGUAGE AND HAVE_opencv_cudaarithm AND HAVE_opencv_cudaimgproc) ocv_target_link_libraries(${the_module} PRIVATE CUDA::cudart${CUDA_LIB_EXT}) diff --git a/modules/photo/src/seamless_cloning.cpp b/modules/photo/src/seamless_cloning.cpp index 529506bd96..1b9e3d1135 100644 --- a/modules/photo/src/seamless_cloning.cpp +++ b/modules/photo/src/seamless_cloning.cpp @@ -41,7 +41,7 @@ #include "precomp.hpp" #include "opencv2/photo.hpp" -#include "opencv2/3d.hpp" +#include "opencv2/geometry.hpp" #include "seamless_cloning.hpp" diff --git a/modules/python/src2/cv2.cpp b/modules/python/src2/cv2.cpp index 87ffd72790..129b961698 100644 --- a/modules/python/src2/cv2.cpp +++ b/modules/python/src2/cv2.cpp @@ -46,9 +46,9 @@ typedef std::vector vector_Scalar; #ifdef HAVE_OPENCV_OBJDETECT typedef std::vector vector_Dictionary; #endif // HAVE_OPENCV_OBJDETECT -#ifdef HAVE_OPENCV_3D +#ifdef HAVE_OPENCV_GEOMETRY typedef std::vector vector_MSTEdge; -#endif // HAVE_OPENCV_3D +#endif // HAVE_OPENCV_GEOMETRY typedef std::vector > vector_vector_char; typedef std::vector > vector_vector_Point; diff --git a/modules/python/src2/hdr_parser.py b/modules/python/src2/hdr_parser.py index be017ce63b..eb92abf101 100755 --- a/modules/python/src2/hdr_parser.py +++ b/modules/python/src2/hdr_parser.py @@ -11,7 +11,7 @@ opencv_hdr_list = [ "../../flann/include/opencv2/flann/miniflann.hpp", "../../ml/include/opencv2/ml.hpp", "../../imgproc/include/opencv2/imgproc.hpp", -"../../3d/include/opencv2/3d.hpp", +"../../geometry/include/opencv2/geometry.hpp", "../../stereo/include/opencv2/stereo.hpp", "../../calib/include/opencv2/calib.hpp", "../../features/include/opencv2/features.hpp", diff --git a/modules/stereo/CMakeLists.txt b/modules/stereo/CMakeLists.txt index ab493af050..5f9fb43cea 100644 --- a/modules/stereo/CMakeLists.txt +++ b/modules/stereo/CMakeLists.txt @@ -4,6 +4,6 @@ set(debug_modules "") if(DEBUG_opencv_stereo) list(APPEND debug_modules opencv_highgui) endif() -ocv_define_module(stereo opencv_imgproc opencv_3d ${debug_modules} +ocv_define_module(stereo opencv_imgproc opencv_geometry ${debug_modules} WRAP java objc python js ) diff --git a/modules/stereo/misc/java/test/StereoBaseTest.java b/modules/stereo/misc/java/test/StereoBaseTest.java index cbb827c4d9..50da4dea59 100644 --- a/modules/stereo/misc/java/test/StereoBaseTest.java +++ b/modules/stereo/misc/java/test/StereoBaseTest.java @@ -2,7 +2,6 @@ package org.opencv.test.stereoBase; import java.util.ArrayList; -import org.opencv.cv3d.Cv3d; import org.opencv.stereo.Stereo; import org.opencv.core.Core; import org.opencv.core.CvType; diff --git a/modules/stereo/src/precomp.hpp b/modules/stereo/src/precomp.hpp index 24f8f675b8..deff149de6 100644 --- a/modules/stereo/src/precomp.hpp +++ b/modules/stereo/src/precomp.hpp @@ -46,7 +46,7 @@ #include "opencv2/core/private.hpp" #include "opencv2/stereo.hpp" -#include "opencv2/3d.hpp" +#include "opencv2/geometry.hpp" #include "opencv2/imgproc.hpp" #include "opencv2/core/ocl.hpp" diff --git a/modules/stereo/test/test_geometry.cpp b/modules/stereo/test/test_geometry.cpp index e57c87d372..4e1ed4f16c 100644 --- a/modules/stereo/test/test_geometry.cpp +++ b/modules/stereo/test/test_geometry.cpp @@ -4,7 +4,7 @@ #include "test_precomp.hpp" #include // EXPECT_MAT_NEAR -#include "opencv2/3d.hpp" +#include "opencv2/geometry.hpp" #include namespace opencv_test { namespace { diff --git a/modules/stitching/CMakeLists.txt b/modules/stitching/CMakeLists.txt index f09e44cc55..d33c0e77eb 100644 --- a/modules/stitching/CMakeLists.txt +++ b/modules/stitching/CMakeLists.txt @@ -8,7 +8,7 @@ set(STITCHING_CONTRIB_DEPS "opencv_xfeatures2d") if(BUILD_SHARED_LIBS AND BUILD_opencv_world AND OPENCV_WORLD_EXCLUDE_EXTRA_MODULES) set(STITCHING_CONTRIB_DEPS "") endif() -ocv_define_module(stitching opencv_imgproc opencv_features opencv_3d opencv_flann +ocv_define_module(stitching opencv_imgproc opencv_features opencv_geometry opencv_flann OPTIONAL opencv_cudaarithm opencv_cudawarping opencv_cudafeatures2d opencv_cudalegacy opencv_cudaimgproc ${STITCHING_CONTRIB_DEPS} WRAP python) diff --git a/modules/stitching/src/precomp.hpp b/modules/stitching/src/precomp.hpp index 90194d2461..b0971175f7 100644 --- a/modules/stitching/src/precomp.hpp +++ b/modules/stitching/src/precomp.hpp @@ -70,7 +70,7 @@ #include "opencv2/stitching/detail/warpers.hpp" #include "opencv2/imgproc.hpp" #include "opencv2/features.hpp" -#include "opencv2/3d.hpp" +#include "opencv2/geometry.hpp" #ifdef HAVE_OPENCV_CUDAARITHM # include "opencv2/cudaarithm.hpp" diff --git a/modules/video/CMakeLists.txt b/modules/video/CMakeLists.txt index 3e4d613c9f..8d47712dcf 100644 --- a/modules/video/CMakeLists.txt +++ b/modules/video/CMakeLists.txt @@ -3,7 +3,7 @@ ocv_add_dispatched_file(lkpyramid SSE2 SSE4_1 AVX2 AVX512_SKX AVX512_ICL) ocv_define_module(video opencv_imgproc OPTIONAL - opencv_3d + opencv_geometry opencv_features opencv_dnn WRAP diff --git a/modules/video/perf/opencl/perf_optflow_pyrlk.cpp b/modules/video/perf/opencl/perf_optflow_pyrlk.cpp index 5834ad1240..f1aadc81f2 100644 --- a/modules/video/perf/opencl/perf_optflow_pyrlk.cpp +++ b/modules/video/perf/opencl/perf_optflow_pyrlk.cpp @@ -46,9 +46,11 @@ #include "../perf_precomp.hpp" #include "opencv2/ts/ocl_perf.hpp" +#ifdef HAVE_OPENCV_FEATURES #include "opencv2/features.hpp" +#endif -#ifdef HAVE_OPENCL +#if defined(HAVE_OPENCL) && defined(HAVE_OPENCV_FEATURES) namespace opencv_test { namespace ocl { diff --git a/modules/video/src/lkpyramid.cpp b/modules/video/src/lkpyramid.cpp index 6a01c03a5d..84c766f61a 100644 --- a/modules/video/src/lkpyramid.cpp +++ b/modules/video/src/lkpyramid.cpp @@ -46,8 +46,8 @@ #include "lkpyramid.hpp" #include "opencl_kernels_video.hpp" #include "opencv2/core/hal/intrin.hpp" -#ifdef HAVE_OPENCV_3D -#include "opencv2/3d.hpp" +#ifdef HAVE_OPENCV_GEOMETRY +#include "opencv2/geometry.hpp" #endif #include "hal_replacement.hpp" @@ -1213,9 +1213,9 @@ void cv::calcOpticalFlowPyrLK( InputArray _prevImg, InputArray _nextImg, cv::Mat cv::estimateRigidTransform( InputArray src1, InputArray src2, bool fullAffine ) { CV_INSTRUMENT_REGION(); -#ifndef HAVE_OPENCV_3D +#ifndef HAVE_OPENCV_GEOMETRY CV_UNUSED(src1); CV_UNUSED(src2); CV_UNUSED(fullAffine); - CV_Error(Error::StsError, "estimateRigidTransform requires 3d module"); + CV_Error(Error::StsError, "estimateRigidTransform requires geometry module"); #else Mat A = src1.getMat(), B = src2.getMat(); diff --git a/modules/video/test/ocl/test_optflowpyrlk.cpp b/modules/video/test/ocl/test_optflowpyrlk.cpp index e3c5bada37..a4e1450165 100644 --- a/modules/video/test/ocl/test_optflowpyrlk.cpp +++ b/modules/video/test/ocl/test_optflowpyrlk.cpp @@ -44,10 +44,12 @@ #include "../test_precomp.hpp" #include "opencv2/ts/ocl_test.hpp" +#ifdef HAVE_OPENCV_FEATURES #include "opencv2/features.hpp" +#endif -#ifdef HAVE_OPENCL +#if defined(HAVE_OPENCL) && defined(HAVE_OPENCV_FEATURES) namespace opencv_test { namespace ocl { diff --git a/samples/android/camera-calibration/src/org/opencv/samples/cameracalibration/CameraCalibrator.java b/samples/android/camera-calibration/src/org/opencv/samples/cameracalibration/CameraCalibrator.java index 670305b25e..c42ad2a94b 100644 --- a/samples/android/camera-calibration/src/org/opencv/samples/cameracalibration/CameraCalibrator.java +++ b/samples/android/camera-calibration/src/org/opencv/samples/cameracalibration/CameraCalibrator.java @@ -3,7 +3,7 @@ package org.opencv.samples.cameracalibration; import java.util.ArrayList; import java.util.List; -import org.opencv.cv3d.Cv3d; +import org.opencv.geometry.Geometry; import org.opencv.calib.Calib; import org.opencv.core.Core; import org.opencv.core.CvType; @@ -109,7 +109,7 @@ public class CameraCalibrator { int totalPoints = 0; for (int i = 0; i < objectPoints.size(); i++) { MatOfPoint3f points = new MatOfPoint3f(objectPoints.get(i)); - Cv3d.projectPoints(points, rvecs.get(i), tvecs.get(i), + Geometry.projectPoints(points, rvecs.get(i), tvecs.get(i), mCameraMatrix, distortionCoefficients, cornersProjected); error = Core.norm(mCornersBuffer.get(i), cornersProjected, Core.NORM_L2); diff --git a/samples/android/camera-calibration/src/org/opencv/samples/cameracalibration/OnCameraFrameRender.java b/samples/android/camera-calibration/src/org/opencv/samples/cameracalibration/OnCameraFrameRender.java index 5cf9e5a9e6..5b185292c0 100644 --- a/samples/android/camera-calibration/src/org/opencv/samples/cameracalibration/OnCameraFrameRender.java +++ b/samples/android/camera-calibration/src/org/opencv/samples/cameracalibration/OnCameraFrameRender.java @@ -4,7 +4,7 @@ import java.util.ArrayList; import java.util.List; import org.opencv.android.CameraBridgeViewBase.CvCameraViewFrame; -import org.opencv.cv3d.Cv3d; +import org.opencv.geometry.Geometry; import org.opencv.calib.Calib; import org.opencv.core.Core; import org.opencv.core.Mat; @@ -52,7 +52,7 @@ class UndistortionFrameRender extends FrameRender { @Override public Mat render(CvCameraViewFrame inputFrame) { Mat renderedFrame = new Mat(inputFrame.rgba().size(), inputFrame.rgba().type()); - Cv3d.undistort(inputFrame.rgba(), renderedFrame, + Geometry.undistort(inputFrame.rgba(), renderedFrame, mCalibrator.getCameraMatrix(), mCalibrator.getDistortionCoefficients()); return renderedFrame; @@ -73,7 +73,7 @@ class ComparisonFrameRender extends FrameRender { @Override public Mat render(CvCameraViewFrame inputFrame) { Mat undistortedFrame = new Mat(inputFrame.rgba().size(), inputFrame.rgba().type()); - Cv3d.undistort(inputFrame.rgba(), undistortedFrame, + Geometry.undistort(inputFrame.rgba(), undistortedFrame, mCalibrator.getCameraMatrix(), mCalibrator.getDistortionCoefficients()); Mat comparisonFrame = inputFrame.rgba(); diff --git a/samples/cpp/3calibration.cpp b/samples/cpp/3calibration.cpp index 0dbe2d5df8..d3d9a361fb 100644 --- a/samples/cpp/3calibration.cpp +++ b/samples/cpp/3calibration.cpp @@ -2,7 +2,7 @@ * 3calibration.cpp -- Calibrate 3 cameras in a horizontal line together. */ -#include "opencv2/3d.hpp" +#include "opencv2/geometry.hpp" #include "opencv2/stereo.hpp" #include "opencv2/calib.hpp" #include "opencv2/imgproc.hpp" diff --git a/samples/cpp/CMakeLists.txt b/samples/cpp/CMakeLists.txt index 04da5a93f8..7b3dc822c5 100644 --- a/samples/cpp/CMakeLists.txt +++ b/samples/cpp/CMakeLists.txt @@ -11,7 +11,7 @@ set(OPENCV_CPP_SAMPLES_REQUIRED_DEPS opencv_objdetect opencv_photo opencv_features - opencv_3d + opencv_geometry opencv_stereo opencv_calib opencv_stitching diff --git a/samples/cpp/asift.cpp b/samples/cpp/asift.cpp index 7768c25d7d..7883cdeab0 100644 --- a/samples/cpp/asift.cpp +++ b/samples/cpp/asift.cpp @@ -2,7 +2,7 @@ #include #include #include -#include +#include #include #include #ifdef HAVE_OPENCV_XFEATURES2D diff --git a/samples/cpp/calibration.cpp b/samples/cpp/calibration.cpp index 7e32c5b881..6f99cf7484 100644 --- a/samples/cpp/calibration.cpp +++ b/samples/cpp/calibration.cpp @@ -1,7 +1,7 @@ #include "opencv2/core.hpp" #include "opencv2/core/utility.hpp" #include "opencv2/imgproc.hpp" -#include "opencv2/3d.hpp" +#include "opencv2/geometry.hpp" #include "opencv2/calib.hpp" #include "opencv2/imgcodecs.hpp" #include "opencv2/videoio.hpp" diff --git a/samples/cpp/delaunay2.cpp b/samples/cpp/delaunay2.cpp index 8b58343344..add0585008 100644 --- a/samples/cpp/delaunay2.cpp +++ b/samples/cpp/delaunay2.cpp @@ -1,4 +1,4 @@ -#include +#include #include #include #include diff --git a/samples/cpp/essential_mat_reconstr.cpp b/samples/cpp/essential_mat_reconstr.cpp index 26987fb5ad..5adbca4bf8 100644 --- a/samples/cpp/essential_mat_reconstr.cpp +++ b/samples/cpp/essential_mat_reconstr.cpp @@ -2,7 +2,7 @@ // It is subject to the license terms in the LICENSE file found in the top-level directory // of this distribution and at http://opencv.org/license.html -#include "opencv2/3d.hpp" +#include "opencv2/geometry.hpp" #include "opencv2/features.hpp" #include "opencv2/highgui.hpp" #include "opencv2/imgproc.hpp" diff --git a/samples/cpp/geometry.cpp b/samples/cpp/geometry.cpp index 54825e28e8..7533222805 100644 --- a/samples/cpp/geometry.cpp +++ b/samples/cpp/geometry.cpp @@ -16,7 +16,7 @@ * *********************************************************************************/ -#include "opencv2/3d.hpp" +#include "opencv2/geometry/2d.hpp" #include "opencv2/imgproc.hpp" #include "opencv2/highgui.hpp" #include diff --git a/samples/cpp/select3dobj.cpp b/samples/cpp/select3dobj.cpp index 7366626bcd..9874c86957 100644 --- a/samples/cpp/select3dobj.cpp +++ b/samples/cpp/select3dobj.cpp @@ -11,7 +11,7 @@ #include "opencv2/core.hpp" #include #include "opencv2/imgproc.hpp" -#include "opencv2/3d.hpp" +#include "opencv2/geometry.hpp" #include "opencv2/calib.hpp" #include "opencv2/imgcodecs.hpp" #include "opencv2/objdetect.hpp" diff --git a/samples/cpp/snippets/epipolar_lines.cpp b/samples/cpp/snippets/epipolar_lines.cpp index d58ff531f7..de628ba179 100644 --- a/samples/cpp/snippets/epipolar_lines.cpp +++ b/samples/cpp/snippets/epipolar_lines.cpp @@ -2,7 +2,7 @@ // It is subject to the license terms in the LICENSE file found in the top-level directory // of this distribution and at http://opencv.org/license.html -#include "opencv2/3d.hpp" +#include "opencv2/geometry.hpp" #include "opencv2/features.hpp" #include "opencv2/highgui.hpp" #include "opencv2/imgproc.hpp" @@ -104,4 +104,4 @@ int main(int args, char** argv) { imshow("epipolar lines, image 1, 2", image1); imwrite("epipolar_lines.png", image1); waitKey(0); -} \ No newline at end of file +} diff --git a/samples/cpp/snippets/intersectExample.cpp b/samples/cpp/snippets/intersectExample.cpp index 52135a1fad..1084408435 100644 --- a/samples/cpp/snippets/intersectExample.cpp +++ b/samples/cpp/snippets/intersectExample.cpp @@ -4,7 +4,7 @@ * A program that illustrates intersectConvexConvex in various scenarios */ -#include "opencv2/3d.hpp" +#include "opencv2/geometry.hpp" #include "opencv2/imgproc.hpp" #include "opencv2/highgui.hpp" diff --git a/samples/cpp/snippets/lsd_lines.cpp b/samples/cpp/snippets/lsd_lines.cpp index 2840b485ba..7a24c7a1bd 100644 --- a/samples/cpp/snippets/lsd_lines.cpp +++ b/samples/cpp/snippets/lsd_lines.cpp @@ -1,4 +1,4 @@ -#include "opencv2/3d.hpp" +#include "opencv2/geometry/2d.hpp" #include "opencv2/imgproc.hpp" #include "opencv2/imgcodecs.hpp" #include "opencv2/highgui.hpp" diff --git a/samples/cpp/snippets/squares.cpp b/samples/cpp/snippets/squares.cpp index a873429e12..8138828766 100644 --- a/samples/cpp/snippets/squares.cpp +++ b/samples/cpp/snippets/squares.cpp @@ -4,7 +4,7 @@ // each image #include "opencv2/core.hpp" -#include "opencv2/3d.hpp" +#include "opencv2/geometry.hpp" #include "opencv2/imgproc.hpp" #include "opencv2/imgcodecs.hpp" #include "opencv2/highgui.hpp" diff --git a/samples/cpp/stereo_calib.cpp b/samples/cpp/stereo_calib.cpp index ecd6739ed0..abf6291adc 100644 --- a/samples/cpp/stereo_calib.cpp +++ b/samples/cpp/stereo_calib.cpp @@ -20,7 +20,7 @@ GitHub: https://github.com/opencv/opencv/ ************************************************** */ -#include "opencv2/3d.hpp" +#include "opencv2/geometry.hpp" #include "opencv2/stereo.hpp" #include "opencv2/calib.hpp" #include "opencv2/imgcodecs.hpp" diff --git a/samples/cpp/stereo_match.cpp b/samples/cpp/stereo_match.cpp index 7f83922d2d..4004d1564b 100644 --- a/samples/cpp/stereo_match.cpp +++ b/samples/cpp/stereo_match.cpp @@ -6,7 +6,7 @@ * Copyright 2010 Argus Corp. All rights reserved. * */ -#include "opencv2/3d.hpp" +#include "opencv2/geometry.hpp" #include "opencv2/stereo.hpp" #include "opencv2/imgproc.hpp" #include "opencv2/imgcodecs.hpp" diff --git a/samples/cpp/tutorial_code/ShapeDescriptors/generalContours_demo1.cpp b/samples/cpp/tutorial_code/ShapeDescriptors/generalContours_demo1.cpp index 8f3b5cb0be..eb04253ad2 100644 --- a/samples/cpp/tutorial_code/ShapeDescriptors/generalContours_demo1.cpp +++ b/samples/cpp/tutorial_code/ShapeDescriptors/generalContours_demo1.cpp @@ -6,7 +6,7 @@ #include "opencv2/imgcodecs.hpp" #include "opencv2/highgui.hpp" -#include "opencv2/3d.hpp" +#include "opencv2/geometry.hpp" #include "opencv2/imgproc.hpp" #include diff --git a/samples/cpp/tutorial_code/ShapeDescriptors/generalContours_demo2.cpp b/samples/cpp/tutorial_code/ShapeDescriptors/generalContours_demo2.cpp index 72400209f3..0b1e485672 100644 --- a/samples/cpp/tutorial_code/ShapeDescriptors/generalContours_demo2.cpp +++ b/samples/cpp/tutorial_code/ShapeDescriptors/generalContours_demo2.cpp @@ -6,7 +6,7 @@ #include "opencv2/imgcodecs.hpp" #include "opencv2/highgui.hpp" -#include "opencv2/3d.hpp" +#include "opencv2/geometry.hpp" #include "opencv2/imgproc.hpp" #include diff --git a/samples/cpp/tutorial_code/ShapeDescriptors/hull_demo.cpp b/samples/cpp/tutorial_code/ShapeDescriptors/hull_demo.cpp index 83a560c524..35c9d75f7a 100644 --- a/samples/cpp/tutorial_code/ShapeDescriptors/hull_demo.cpp +++ b/samples/cpp/tutorial_code/ShapeDescriptors/hull_demo.cpp @@ -6,7 +6,7 @@ #include "opencv2/imgcodecs.hpp" #include "opencv2/highgui.hpp" -#include "opencv2/3d.hpp" +#include "opencv2/geometry.hpp" #include "opencv2/imgproc.hpp" #include diff --git a/samples/cpp/tutorial_code/ShapeDescriptors/pointPolygonTest_demo.cpp b/samples/cpp/tutorial_code/ShapeDescriptors/pointPolygonTest_demo.cpp index 236feaf9d9..d03435c516 100644 --- a/samples/cpp/tutorial_code/ShapeDescriptors/pointPolygonTest_demo.cpp +++ b/samples/cpp/tutorial_code/ShapeDescriptors/pointPolygonTest_demo.cpp @@ -5,7 +5,7 @@ */ #include "opencv2/highgui.hpp" -#include "opencv2/3d.hpp" +#include "opencv2/geometry.hpp" #include "opencv2/imgproc.hpp" #include diff --git a/samples/cpp/tutorial_code/calib3d/camera_calibration/camera_calibration.cpp b/samples/cpp/tutorial_code/calib3d/camera_calibration/camera_calibration.cpp index 3f8e5d61ec..cb6ebd3b05 100644 --- a/samples/cpp/tutorial_code/calib3d/camera_calibration/camera_calibration.cpp +++ b/samples/cpp/tutorial_code/calib3d/camera_calibration/camera_calibration.cpp @@ -7,7 +7,7 @@ #include #include #include -#include +#include #include #include #include diff --git a/samples/cpp/tutorial_code/calib3d/real_time_pose_estimation/src/Mesh.cpp b/samples/cpp/tutorial_code/calib3d/real_time_pose_estimation/src/Mesh.cpp index c3eb7fb254..813598bbcc 100644 --- a/samples/cpp/tutorial_code/calib3d/real_time_pose_estimation/src/Mesh.cpp +++ b/samples/cpp/tutorial_code/calib3d/real_time_pose_estimation/src/Mesh.cpp @@ -6,7 +6,7 @@ */ #include "Mesh.h" -#include +#include // --------------------------------------------------- // // TRIANGLE CLASS // diff --git a/samples/cpp/tutorial_code/calib3d/real_time_pose_estimation/src/PnPProblem.cpp b/samples/cpp/tutorial_code/calib3d/real_time_pose_estimation/src/PnPProblem.cpp index c0f0fca4da..4a456876c5 100644 --- a/samples/cpp/tutorial_code/calib3d/real_time_pose_estimation/src/PnPProblem.cpp +++ b/samples/cpp/tutorial_code/calib3d/real_time_pose_estimation/src/PnPProblem.cpp @@ -11,7 +11,7 @@ #include "PnPProblem.h" #include "Mesh.h" -#include +#include /* Functions for Möller-Trumbore intersection algorithm */ static cv::Point3f CROSS(cv::Point3f v1, cv::Point3f v2) diff --git a/samples/cpp/tutorial_code/calib3d/real_time_pose_estimation/src/Utils.cpp b/samples/cpp/tutorial_code/calib3d/real_time_pose_estimation/src/Utils.cpp index d6022549d2..ef2068fb25 100644 --- a/samples/cpp/tutorial_code/calib3d/real_time_pose_estimation/src/Utils.cpp +++ b/samples/cpp/tutorial_code/calib3d/real_time_pose_estimation/src/Utils.cpp @@ -13,7 +13,7 @@ #include #include -#include +#include #include #if defined (HAVE_OPENCV_XFEATURES2D) #include diff --git a/samples/cpp/tutorial_code/calib3d/real_time_pose_estimation/src/main_detection.cpp b/samples/cpp/tutorial_code/calib3d/real_time_pose_estimation/src/main_detection.cpp index 84320d126f..ec536f813d 100644 --- a/samples/cpp/tutorial_code/calib3d/real_time_pose_estimation/src/main_detection.cpp +++ b/samples/cpp/tutorial_code/calib3d/real_time_pose_estimation/src/main_detection.cpp @@ -5,7 +5,7 @@ #include #include #include -#include +#include #include // PnP Tutorial #include "Mesh.h" diff --git a/samples/cpp/tutorial_code/calib3d/real_time_pose_estimation/src/main_registration.cpp b/samples/cpp/tutorial_code/calib3d/real_time_pose_estimation/src/main_registration.cpp index c76e9830e6..9b36f6685e 100644 --- a/samples/cpp/tutorial_code/calib3d/real_time_pose_estimation/src/main_registration.cpp +++ b/samples/cpp/tutorial_code/calib3d/real_time_pose_estimation/src/main_registration.cpp @@ -3,7 +3,7 @@ // OpenCV #include #include -#include +#include #include // PnP Tutorial #include "Mesh.h" diff --git a/samples/cpp/tutorial_code/features/AKAZE_tracking/planar_tracking.cpp b/samples/cpp/tutorial_code/features/AKAZE_tracking/planar_tracking.cpp index ad19221c18..a270574e39 100644 --- a/samples/cpp/tutorial_code/features/AKAZE_tracking/planar_tracking.cpp +++ b/samples/cpp/tutorial_code/features/AKAZE_tracking/planar_tracking.cpp @@ -7,7 +7,7 @@ #include "opencv2/xfeatures2d.hpp" #include #include -#include +#include #include //for imshow #include "stats.h" // Stats structure definition @@ -220,4 +220,4 @@ int main() std::cout << "This tutorial code needs the xfeatures2d contrib module to be run." << std::endl; return 0; } -#endif \ No newline at end of file +#endif diff --git a/samples/cpp/tutorial_code/features/Homography/decompose_homography.cpp b/samples/cpp/tutorial_code/features/Homography/decompose_homography.cpp index 8e9872a835..d7e915467a 100644 --- a/samples/cpp/tutorial_code/features/Homography/decompose_homography.cpp +++ b/samples/cpp/tutorial_code/features/Homography/decompose_homography.cpp @@ -1,7 +1,7 @@ #include #include #include -#include +#include #include #include diff --git a/samples/cpp/tutorial_code/features/Homography/homography_from_camera_displacement.cpp b/samples/cpp/tutorial_code/features/Homography/homography_from_camera_displacement.cpp index d1167361e4..052c4f4759 100644 --- a/samples/cpp/tutorial_code/features/Homography/homography_from_camera_displacement.cpp +++ b/samples/cpp/tutorial_code/features/Homography/homography_from_camera_displacement.cpp @@ -2,7 +2,7 @@ #include #include #include -#include +#include #include #include diff --git a/samples/cpp/tutorial_code/features/Homography/perspective_correction.cpp b/samples/cpp/tutorial_code/features/Homography/perspective_correction.cpp index 9180dc719a..78c21b8ff7 100644 --- a/samples/cpp/tutorial_code/features/Homography/perspective_correction.cpp +++ b/samples/cpp/tutorial_code/features/Homography/perspective_correction.cpp @@ -1,7 +1,7 @@ #include #include #include -#include +#include #include #include #include diff --git a/samples/cpp/tutorial_code/features/Homography/pose_from_homography.cpp b/samples/cpp/tutorial_code/features/Homography/pose_from_homography.cpp index 6a379f1fa0..aeddf2f2a0 100644 --- a/samples/cpp/tutorial_code/features/Homography/pose_from_homography.cpp +++ b/samples/cpp/tutorial_code/features/Homography/pose_from_homography.cpp @@ -1,7 +1,7 @@ #include #include #include -#include +#include #include #include #include diff --git a/samples/cpp/tutorial_code/features/feature_homography/SURF_FLANN_matching_homography_Demo.cpp b/samples/cpp/tutorial_code/features/feature_homography/SURF_FLANN_matching_homography_Demo.cpp index 5aad669c25..722d023ae1 100644 --- a/samples/cpp/tutorial_code/features/feature_homography/SURF_FLANN_matching_homography_Demo.cpp +++ b/samples/cpp/tutorial_code/features/feature_homography/SURF_FLANN_matching_homography_Demo.cpp @@ -1,7 +1,7 @@ #include #include "opencv2/core.hpp" #ifdef HAVE_OPENCV_XFEATURES2D -#include "opencv2/3d.hpp" +#include "opencv2/geometry.hpp" #include "opencv2/highgui.hpp" #include "opencv2/imgproc.hpp" #include "opencv2/features.hpp" diff --git a/samples/cpp/tutorial_code/snippets/3d_sac_segmentation.cpp b/samples/cpp/tutorial_code/snippets/3d_sac_segmentation.cpp index 130369fe02..8f7b5fc31b 100644 --- a/samples/cpp/tutorial_code/snippets/3d_sac_segmentation.cpp +++ b/samples/cpp/tutorial_code/snippets/3d_sac_segmentation.cpp @@ -11,7 +11,7 @@ */ #include -#include +#include bool customFunc(const std::vector &model_coefficients); @@ -87,4 +87,4 @@ int planeSegmentationUsingRANSAC(const cv::Mat &pt_cloud, int main() { -} \ No newline at end of file +} diff --git a/samples/gpu/CMakeLists.txt b/samples/gpu/CMakeLists.txt index f14689fe43..28b29aaa7f 100644 --- a/samples/gpu/CMakeLists.txt +++ b/samples/gpu/CMakeLists.txt @@ -11,7 +11,7 @@ set(OPENCV_CUDA_SAMPLES_REQUIRED_DEPS opencv_video opencv_objdetect opencv_features - opencv_3d + opencv_geometry opencv_superres opencv_cudaarithm opencv_cudafilters diff --git a/samples/java/tutorial_code/features/Homography/PerspectiveCorrection.java b/samples/java/tutorial_code/features/Homography/PerspectiveCorrection.java index ac94462295..c0fea4870f 100644 --- a/samples/java/tutorial_code/features/Homography/PerspectiveCorrection.java +++ b/samples/java/tutorial_code/features/Homography/PerspectiveCorrection.java @@ -3,7 +3,7 @@ import java.util.List; import java.util.Random; import org.opencv.core.*; -import org.opencv.3d.Cv3d; +import org.opencv.geometry.Geometry; import org.opencv.calib.Calib; import org.opencv.highgui.HighGui; import org.opencv.imgcodecs.Imgcodecs; @@ -29,7 +29,7 @@ class PerspectiveCorrectionRun { //! [estimate-homography] Mat H = new Mat(); - H = Cv3d.findHomography(corners1, corners2); + H = Geometry.findHomography(corners1, corners2); System.out.println(H.dump()); //! [estimate-homography] diff --git a/samples/java/tutorial_code/features/feature_homography/SURFFLANNMatchingHomographyDemo.java b/samples/java/tutorial_code/features/feature_homography/SURFFLANNMatchingHomographyDemo.java index feeb04ce77..f23106e031 100644 --- a/samples/java/tutorial_code/features/feature_homography/SURFFLANNMatchingHomographyDemo.java +++ b/samples/java/tutorial_code/features/feature_homography/SURFFLANNMatchingHomographyDemo.java @@ -1,7 +1,7 @@ import java.util.ArrayList; import java.util.List; -import org.opencv._3d; +import org.opencv.geometry.Geometry; import org.opencv.core.Core; import org.opencv.core.CvType; import org.opencv.core.DMatch; @@ -82,7 +82,7 @@ class SURFFLANNMatchingHomography { objMat.fromList(obj); sceneMat.fromList(scene); double ransacReprojThreshold = 3.0; - Mat H = Cv3d.findHomography( objMat, sceneMat, Cv3d.RANSAC, ransacReprojThreshold ); + Mat H = Geometry.findHomography( objMat, sceneMat, Geometry.RANSAC, ransacReprojThreshold ); //-- Get the corners from the image_1 ( the object to be "detected" ) Mat objCorners = new Mat(4, 1, CvType.CV_32FC2), sceneCorners = new Mat(); diff --git a/samples/opengl/CMakeLists.txt b/samples/opengl/CMakeLists.txt index 7ba102e856..b322d98d72 100644 --- a/samples/opengl/CMakeLists.txt +++ b/samples/opengl/CMakeLists.txt @@ -13,7 +13,7 @@ SET(OPENCV_OPENGL_SAMPLES_REQUIRED_DEPS opencv_core opencv_imgproc opencv_imgcodecs - opencv_3d + opencv_geometry opencv_videoio opencv_highgui) ocv_check_dependencies(${OPENCV_OPENGL_SAMPLES_REQUIRED_DEPS}) diff --git a/samples/opengl/opengl_testdata_generator.cpp b/samples/opengl/opengl_testdata_generator.cpp index e1c29f5d40..2b88ea95a9 100644 --- a/samples/opengl/opengl_testdata_generator.cpp +++ b/samples/opengl/opengl_testdata_generator.cpp @@ -17,9 +17,9 @@ #include "opencv2/core.hpp" #include "opencv2/core/opengl.hpp" -#include "opencv2/3d.hpp" #include "opencv2/imgproc.hpp" #include "opencv2/highgui.hpp" +#include "opencv2/geometry.hpp" using namespace std; using namespace cv; diff --git a/samples/tapi/CMakeLists.txt b/samples/tapi/CMakeLists.txt index ee75b83746..0a4bae9c30 100644 --- a/samples/tapi/CMakeLists.txt +++ b/samples/tapi/CMakeLists.txt @@ -9,7 +9,7 @@ set(OPENCV_TAPI_SAMPLES_REQUIRED_DEPS opencv_highgui opencv_objdetect opencv_features - opencv_3d + opencv_geometry opencv_stereo opencv_flann) ocv_check_dependencies(${OPENCV_TAPI_SAMPLES_REQUIRED_DEPS}) diff --git a/samples/tapi/squares.cpp b/samples/tapi/squares.cpp index 46ad775035..a72d8581aa 100644 --- a/samples/tapi/squares.cpp +++ b/samples/tapi/squares.cpp @@ -2,7 +2,7 @@ #include "opencv2/core.hpp" #include "opencv2/core/ocl.hpp" #include "opencv2/core/utility.hpp" -#include "opencv2/3d.hpp" +#include "opencv2/geometry/2d.hpp" #include "opencv2/imgproc.hpp" #include "opencv2/imgcodecs.hpp" #include "opencv2/highgui.hpp"