diff --git a/modules/calib3d/doc/camera_calibration_and_3d_reconstruction.rst b/modules/calib3d/doc/camera_calibration_and_3d_reconstruction.rst index 08a9b196f6..3a7a88fba9 100644 --- a/modules/calib3d/doc/camera_calibration_and_3d_reconstruction.rst +++ b/modules/calib3d/doc/camera_calibration_and_3d_reconstruction.rst @@ -1,8 +1,6 @@ Camera Calibration and 3D Reconstruction ======================================== -.. highlight:: cpp - The functions in this section use the so-called pinhole camera model. That is, a scene view is formed by projecting 3D points into the image plane using a perspective transformation. @@ -15,8 +13,7 @@ or .. math:: - s \vecthree{u}{v}{1} = \vecthreethree{f_x}{0}{c_x}{0}{f_y}{c_y}{0}{0}{1} - + s \vecthree{u}{v}{1} = \vecthreethree{f_x}{0}{c_x}{0}{f_y}{c_y}{0}{0}{1} \begin{bmatrix} r_{11} & r_{12} & r_{13} & t_1 \\ r_{21} & r_{22} & r_{23} & t_2 \\ diff --git a/modules/core/doc/core.rst b/modules/core/doc/core.rst index aff11e7369..b510e458fa 100644 --- a/modules/core/doc/core.rst +++ b/modules/core/doc/core.rst @@ -7,7 +7,6 @@ core. The Core Functionality basic_structures operations_on_arrays - dynamic_structures drawing_functions xml_yaml_persistence clustering diff --git a/modules/core/doc/intro.rst b/modules/core/doc/intro.rst index 78749d35ad..569fe50beb 100644 --- a/modules/core/doc/intro.rst +++ b/modules/core/doc/intro.rst @@ -2,8 +2,6 @@ Introduction ************ -.. highlight:: cpp - OpenCV (Open Source Computer Vision Library: http://opencv.willowgarage.com/wiki/) is open-source BSD-licensed library that includes several hundreds computer vision algorithms. It is very popular in the Computer Vision community. Some people call it “de-facto standard” API. The document aims to specify the stable parts of the library, as well as some abstract interfaces for high-level interfaces, with the final goal to make it an official standard. API specifications in the document use the standard C++ (http://www.open-std.org/jtc1/sc22/wg21/) and the standard C++ library. diff --git a/modules/features2d/doc/common_interfaces_of_feature_detectors.rst b/modules/features2d/doc/common_interfaces_of_feature_detectors.rst index d7b1a26b49..787d3539a9 100644 --- a/modules/features2d/doc/common_interfaces_of_feature_detectors.rst +++ b/modules/features2d/doc/common_interfaces_of_feature_detectors.rst @@ -1,8 +1,6 @@ Common Interfaces of Feature Detectors ====================================== -.. highlight:: cpp - Feature detectors in OpenCV have wrappers with common interface that enables to switch easily between different algorithms solving the same problem. All objects that implement keypoint detectors inherit @@ -1005,11 +1003,10 @@ AdjusterAdapter::good Are params maxed out or still valid? Returns false if the parameters can't be adjusted any more. An example implementation of this is :: - bool FastAdjuster::good() const - { - return (thresh_ > 1) && (thresh_ < 200); - } - + bool FastAdjuster::good() const + { + return (thresh > 1) && (thresh < 200); + } .. index:: FastAdjuster diff --git a/modules/features2d/doc/common_interfaces_of_generic_descriptor_matchers.rst b/modules/features2d/doc/common_interfaces_of_generic_descriptor_matchers.rst index 3cfcc9fa11..2f2561f1c1 100644 --- a/modules/features2d/doc/common_interfaces_of_generic_descriptor_matchers.rst +++ b/modules/features2d/doc/common_interfaces_of_generic_descriptor_matchers.rst @@ -14,21 +14,11 @@ There are descriptors such as One way descriptor and Ferns that have ``GenericDe .. index:: GenericDescriptorMatcher -.. _GenericDescriptorMatcher: - GenericDescriptorMatcher ------------------------ .. c:type:: GenericDescriptorMatcher -Abstract interface for a keypoint descriptor extracting and matching. -There is -:func:`DescriptorExtractor` and -:func:`DescriptorMatcher` for these purposes too, but their interfaces are intended for descriptors -represented as vectors in a multidimensional space. ``GenericDescriptorMatcher`` is a more generic interface for descriptors. - -:func:`DescriptorMatcher`,``GenericDescriptorMatcher`` has two groups -of match methods: for matching keypoints of one image with other image or -with image set. :: +Abstract interface for a keypoint descriptor extracting and matching. There is :func:`DescriptorExtractor` and :func:`DescriptorMatcher` for these purposes too, but their interfaces are intended for descriptors represented as vectors in a multidimensional space. ``GenericDescriptorMatcher`` is a more generic interface for descriptors. :func:`DescriptorMatcher`,``GenericDescriptorMatcher`` has two groups of match methods: for matching keypoints of one image with other image or with image set. :: class GenericDescriptorMatcher { diff --git a/modules/features2d/doc/drawing_function_of_keypoints_and_matches.rst b/modules/features2d/doc/drawing_function_of_keypoints_and_matches.rst index 8a14cd6723..c92054ef75 100644 --- a/modules/features2d/doc/drawing_function_of_keypoints_and_matches.rst +++ b/modules/features2d/doc/drawing_function_of_keypoints_and_matches.rst @@ -1,15 +1,12 @@ Drawing Function of Keypoints and Matches ========================================= -.. highlight:: cpp - .. index:: drawMatches drawMatches --------------- -.. c:function:: void drawMatches( const Mat& img1, const vector& keypoints1, const Mat& img2, const vector& keypoints2, const vector& matches1to2, Mat& outImg, const Scalar& matchColor=Scalar::all(-1), const Scalar& singlePointColor=Scalar::all(-1), const vector& matchesMask=vector(), int flags=DrawMatchesFlags::DEFAULT ) - This function draws matches of keypints from two images on output image. Match is a line connecting two keypoints (circles). +.. c:function:: void drawMatches( const Mat& img1, const vector& keypoints1, const Mat& img2, const vector& keypoints2, const vector& matches1to2, Mat& outImg, const Scalar& matchColor=Scalar::all(-1), const Scalar& singlePointColor=Scalar::all(-1), const vector& matchesMask=vector(), int flags=DrawMatchesFlags::DEFAULT ) .. c:function:: void drawMatches( const Mat& img1, const vector& keypoints1, const Mat& img2, const vector& keypoints2, const vector >& matches1to2, Mat& outImg, const Scalar& matchColor=Scalar::all(-1), const Scalar& singlePointColor=Scalar::all(-1), const vector>& matchesMask= vector >(), int flags=DrawMatchesFlags::DEFAULT ) @@ -31,29 +28,34 @@ drawMatches :param matchesMask: Mask determining which matches will be drawn. If mask is empty all matches will be drawn. - :param flags: Each bit of ``flags`` sets some feature of drawing. Possible ``flags`` bit values is defined by ``DrawMatchesFlags`` :: + :param flags: Each bit of ``flags`` sets some feature of drawing. Possible ``flags`` bit values is defined by ``DrawMatchesFlags``. + +This function draws matches of keypints from two images on output image. Match is a line connecting two keypoints (circles). The structure ``DrawMatchesFlags`` is defined as follows: - struct DrawMatchesFlags - { - enum{ DEFAULT = 0, // Output image matrix will be created (Mat::create), - // i.e. existing memory of output image may be reused. - // Two source image, matches and single keypoints - // will be drawn. - // For each keypoint only the center point will be - // drawn (without the circle around keypoint with - // keypoint size and orientation). - DRAW_OVER_OUTIMG = 1, // Output image matrix will not be - // created (Mat::create). Matches will be drawn - // on existing content of output image. - NOT_DRAW_SINGLE_POINTS = 2, // Single keypoints will not be drawn. - DRAW_RICH_KEYPOINTS = 4 // For each keypoint the circle around - // keypoint with keypoint size and orientation will - // be drawn. - }; - }; - - .. +.. code-block:: cpp + struct DrawMatchesFlags + { + enum + { + DEFAULT = 0, // Output image matrix will be created (Mat::create), + // i.e. existing memory of output image may be reused. + // Two source image, matches and single keypoints + // will be drawn. + // For each keypoint only the center point will be + // drawn (without the circle around keypoint with + // keypoint size and orientation). + DRAW_OVER_OUTIMG = 1, // Output image matrix will not be + // created (using Mat::create). Matches will be drawn + // on existing content of output image. + NOT_DRAW_SINGLE_POINTS = 2, // Single keypoints will not be drawn. + DRAW_RICH_KEYPOINTS = 4 // For each keypoint the circle around + // keypoint with keypoint size and orientation will + // be drawn. + }; + }; + +.. .. index:: drawKeypoints diff --git a/modules/gpu/doc/gpu.rst b/modules/gpu/doc/gpu.rst index 41a8309c25..423fd4be6e 100644 --- a/modules/gpu/doc/gpu.rst +++ b/modules/gpu/doc/gpu.rst @@ -9,7 +9,7 @@ gpu. GPU-accelerated Computer Vision initalization_and_information data_structures operations_on_matrices - per_element_operations. + per_element_operations image_processing matrix_reductions object_detection diff --git a/modules/gpu/doc/per_element_operations.rst b/modules/gpu/doc/per_element_operations.rst new file mode 100644 index 0000000000..c52674c880 --- /dev/null +++ b/modules/gpu/doc/per_element_operations.rst @@ -0,0 +1,365 @@ +Per-element Operations. +======================= + +.. highlight:: cpp + +.. index:: gpu::add + +gpu::add +------------ +.. c:function:: void gpu::add(const GpuMat\& a, const GpuMat\& b, GpuMat\& c) + + Computes matrix-matrix or matrix-scalar sum. + + :param a: First source matrix. ``CV_8UC1`` , ``CV_8UC4`` , ``CV_32SC1`` and ``CV_32FC1`` matrices are supported for now. + + :param b: Second source matrix. Must have the same size and type as ``a`` . + + :param c: Destination matrix. Will have the same size and type as ``a`` . + +.. c:function:: void gpu::add(const GpuMat\& a, const Scalar\& sc, GpuMat\& c) + + * **a** Source matrix. ``CV_32FC1`` and ``CV_32FC2`` matrixes are supported for now. + + * **b** Source scalar to be added to the source matrix. + + * **c** Destination matrix. Will have the same size and type as ``a`` . + +See also: +:func:`add` . + +.. index:: gpu::subtract + +gpu::subtract +----------------- +.. c:function:: void gpu::subtract(const GpuMat\& a, const GpuMat\& b, GpuMat\& c) + + Subtracts matrix from another matrix (or scalar from matrix). + + :param a: First source matrix. ``CV_8UC1`` , ``CV_8UC4`` , ``CV_32SC1`` and ``CV_32FC1`` matrices are supported for now. + + :param b: Second source matrix. Must have the same size and type as ``a`` . + + :param c: Destination matrix. Will have the same size and type as ``a`` . + +.. c:function:: void subtract(const GpuMat\& a, const Scalar\& sc, GpuMat\& c) + + * **a** Source matrix. ``CV_32FC1`` and ``CV_32FC2`` matrixes are supported for now. + + * **b** Scalar to be subtracted from the source matrix elements. + + * **c** Destination matrix. Will have the same size and type as ``a`` . + +See also: +:func:`subtract` . + +.. index:: gpu::multiply + +gpu::multiply +----------------- +.. c:function:: void gpu::multiply(const GpuMat\& a, const GpuMat\& b, GpuMat\& c) + + Computes per-element product of two matrices (or of matrix and scalar). + + :param a: First source matrix. ``CV_8UC1`` , ``CV_8UC4`` , ``CV_32SC1`` and ``CV_32FC1`` matrices are supported for now. + + :param b: Second source matrix. Must have the same size and type as ``a`` . + + :param c: Destionation matrix. Will have the same size and type as ``a`` . + +.. c:function:: void multiply(const GpuMat\& a, const Scalar\& sc, GpuMat\& c) + + * **a** Source matrix. ``CV_32FC1`` and ``CV_32FC2`` matrixes are supported for now. + + * **b** Scalar to be multiplied by. + + * **c** Destination matrix. Will have the same size and type as ``a`` . + +See also: +:func:`multiply` . + +.. index:: gpu::divide + +gpu::divide +--------------- +.. c:function:: void gpu::divide(const GpuMat\& a, const GpuMat\& b, GpuMat\& c) + + Performs per-element division of two matrices (or division of matrix by scalar). + + :param a: First source matrix. ``CV_8UC1`` , ``CV_8UC4`` , ``CV_32SC1`` and ``CV_32FC1`` matrices are supported for now. + + :param b: Second source matrix. Must have the same size and type as ``a`` . + + :param c: Destionation matrix. Will have the same size and type as ``a`` . + +.. c:function:: void divide(const GpuMat\& a, const Scalar\& sc, GpuMat\& c) + + * **a** Source matrix. ``CV_32FC1`` and ``CV_32FC2`` matrixes are supported for now. + + * **b** Scalar to be divided by. + + * **c** Destination matrix. Will have the same size and type as ``a`` . + +This function in contrast to +:func:`divide` uses round-down rounding mode. + +See also: +:func:`divide` . + +.. index:: gpu::exp + +gpu::exp +------------ +.. c:function:: void gpu::exp(const GpuMat\& a, GpuMat\& b) + + Computes exponent of each matrix element. + + :param a: Source matrix. ``CV_32FC1`` matrixes are supported for now. + + :param b: Destination matrix. Will have the same size and type as ``a`` . + +See also: +:func:`exp` . + +.. index:: gpu::log + +gpu::log +------------ +.. c:function:: void gpu::log(const GpuMat\& a, GpuMat\& b) + + Computes natural logarithm of absolute value of each matrix element. + + :param a: Source matrix. ``CV_32FC1`` matrixes are supported for now. + + :param b: Destination matrix. Will have the same size and type as ``a`` . + +See also: +:func:`log` . + +.. index:: gpu::absdiff + +gpu::absdiff +---------------- +.. c:function:: void gpu::absdiff(const GpuMat\& a, const GpuMat\& b, GpuMat\& c) + + Computes per-element absolute difference of two matrices (or of matrix and scalar). + + :param a: First source matrix. ``CV_8UC1`` , ``CV_8UC4`` , ``CV_32SC1`` and ``CV_32FC1`` matrices are supported for now. + + :param b: Second source matrix. Must have the same size and type as ``a`` . + + :param c: Destionation matrix. Will have the same size and type as ``a`` . + +.. c:function:: void absdiff(const GpuMat\& a, const Scalar\& s, GpuMat\& c) + + * **a** Source matrix. ``CV_32FC1`` matrixes are supported for now. + + * **b** Scalar to be subtracted from the source matrix elements. + + * **c** Destination matrix. Will have the same size and type as ``a`` . + +See also: +:func:`absdiff` . + +.. index:: gpu::compare + +gpu::compare +---------------- +.. c:function:: void gpu::compare(const GpuMat\& a, const GpuMat\& b, GpuMat\& c, int cmpop) + + Compares elements of two matrices. + + :param a: First source matrix. ``CV_8UC4`` and ``CV_32FC1`` matrices are supported for now. + + :param b: Second source matrix. Must have the same size and type as ``a`` . + + :param c: Destination matrix. Will have the same size as ``a`` and be ``CV_8UC1`` type. + + :param cmpop: Flag specifying the relation between the elements to be checked: + + * **CMP_EQ** :math:`=` + * **CMP_GT** :math:`>` + * **CMP_GE** :math:`\ge` + * **CMP_LT** :math:`<` + * **CMP_LE** :math:`\le` + * **CMP_NE** :math:`\ne` + + +See also: +:func:`compare` . + +.. index:: gpu::bitwise_not + +.. _gpu::bitwise_not: + +gpu::bitwise_not +-------------------- +.. c:function:: void gpu::bitwise_not(const GpuMat\& src, GpuMat\& dst, + const GpuMat\& mask=GpuMat()) + +.. c:function:: void gpu::bitwise_not(const GpuMat\& src, GpuMat\& dst, + const GpuMat\& mask, const Stream\& stream) + + Performs per-element bitwise inversion. + + :param src: Source matrix. + + :param dst: Destination matrix. Will have the same size and type as ``src`` . + + :param mask: Optional operation mask. 8-bit single channel image. + + :param stream: Stream for the asynchronous version. + +See also: +. + +.. index:: gpu::bitwise_or + +.. _gpu::bitwise_or: + +gpu::bitwise_or +------------------- +.. c:function:: void gpu::bitwise_or(const GpuMat\& src1, const GpuMat\& src2, GpuMat\& dst, + const GpuMat\& mask=GpuMat()) + +.. c:function:: void gpu::bitwise_or(const GpuMat\& src1, const GpuMat\& src2, GpuMat\& dst, + const GpuMat\& mask, const Stream\& stream) + + Performs per-element bitwise disjunction of two matrices. + + :param src1: First source matrix. + + :param src2: Second source matrix. It must have the same size and type as ``src1`` . + + :param dst: Destination matrix. Will have the same size and type as ``src1`` . + + :param mask: Optional operation mask. 8-bit single channel image. + + :param stream: Stream for the asynchronous version. + +See also: +. + +.. index:: gpu::bitwise_and + +.. _gpu::bitwise_and: + +gpu::bitwise_and +-------------------- +.. c:function:: void gpu::bitwise_and(const GpuMat\& src1, const GpuMat\& src2, GpuMat\& dst, + const GpuMat\& mask=GpuMat()) + +.. c:function:: void gpu::bitwise_and(const GpuMat\& src1, const GpuMat\& src2, GpuMat\& dst, + const GpuMat\& mask, const Stream\& stream) + + Performs per-element bitwise conjunction of two matrices. + + :param src1: First source matrix. + + :param src2: Second source matrix. It must have the same size and type as ``src1`` . + + :param dst: Destination matrix. Will have the same size and type as ``src1`` . + + :param mask: Optional operation mask. 8-bit single channel image. + + :param stream: Stream for the asynchronous version. + +See also: +. + +.. index:: gpu::bitwise_xor + +.. _gpu::bitwise_xor: + +gpu::bitwise_xor +-------------------- +.. c:function:: void gpu::bitwise_xor(const GpuMat\& src1, const GpuMat\& src2, GpuMat\& dst, + const GpuMat\& mask=GpuMat()) + +.. c:function:: void gpu::bitwise_xor(const GpuMat\& src1, const GpuMat\& src2, GpuMat\& dst, + const GpuMat\& mask, const Stream\& stream) + + Performs per-element bitwise "exclusive or" of two matrices. + + :param src1: First source matrix. + + :param src2: Second source matrix. It must have the same size and type as ``src1`` . + + :param dst: Destination matrix. Will have the same size and type as ``src1`` . + + :param mask: Optional operation mask. 8-bit single channel image. + + :param stream: Stream for the asynchronous version. + +See also: +. + +.. index:: gpu::min + +gpu::min +------------ +.. c:function:: void gpu::min(const GpuMat\& src1, const GpuMat\& src2, GpuMat\& dst) + +.. c:function:: void gpu::min(const GpuMat\& src1, const GpuMat\& src2, GpuMat\& dst, + const Stream\& stream) + + Computes per-element minimum of two matrices (or of matrix and scalar). + + :param src1: First source matrix. + + :param src2: Second source matrix. + + :param dst: Destination matrix. Will have the same size and type as ``src1`` . + + :param stream: Stream for the asynchronous version. + +.. c:function:: void gpu::min(const GpuMat\& src1, double src2, GpuMat\& dst) + +.. c:function:: void gpu::min(const GpuMat\& src1, double src2, GpuMat\& dst, + const Stream\& stream) + + * **src1** Source matrix. + + * **src2** Scalar to be compared with. + + * **dst** Destination matrix. Will have the same size and type as ``src1`` . + + * **stream** Stream for the asynchronous version. + +See also: +:func:`min` . + +.. index:: gpu::max + +gpu::max +------------ +.. c:function:: void gpu::max(const GpuMat\& src1, const GpuMat\& src2, GpuMat\& dst) + +.. c:function:: void gpu::max(const GpuMat\& src1, const GpuMat\& src2, GpuMat\& dst, + const Stream\& stream) + + Computes per-element maximum of two matrices (or of matrix and scalar). + + :param src1: First source matrix. + + :param src2: Second source matrix. + + :param dst: Destination matrix. Will have the same size and type as ``src1`` . + + :param stream: Stream for the asynchronous version. + +.. c:function:: void max(const GpuMat\& src1, double src2, GpuMat\& dst) + +.. c:function:: void max(const GpuMat\& src1, double src2, GpuMat\& dst, + const Stream\& stream) + + * **src1** Source matrix. + + * **src2** Scalar to be compared with. + + * **dst** Destination matrix. Will have the same size and type as ``src1`` . + + * **stream** Stream for the asynchronous version. + +See also: +:func:`max` . diff --git a/modules/highgui/doc/pics/qtgui.png b/modules/highgui/doc/pics/qtgui.png new file mode 100644 index 0000000000..6815d56d9e Binary files /dev/null and b/modules/highgui/doc/pics/qtgui.png differ diff --git a/modules/highgui/doc/qt_new_functions.rst b/modules/highgui/doc/qt_new_functions.rst index 9796ba447e..f39e4726a6 100644 --- a/modules/highgui/doc/qt_new_functions.rst +++ b/modules/highgui/doc/qt_new_functions.rst @@ -1,9 +1,7 @@ Qt new functions ================ -.. highlight:: cpp - -.. image:: ../../pics/Qt_GUI.png +.. image:: pics/qtgui.png This figure explains the new functionalities implemented with Qt GUI. As we can see, the new GUI provides a statusbar, a toolbar, and a control panel. The control panel can have trackbars and buttonbars attached to it. diff --git a/modules/imgproc/doc/feature_detection.rst b/modules/imgproc/doc/feature_detection.rst index 6ac867c73b..e3fc9ff2c5 100644 --- a/modules/imgproc/doc/feature_detection.rst +++ b/modules/imgproc/doc/feature_detection.rst @@ -1,8 +1,6 @@ Feature Detection ================= -.. highlight:: cpp - .. index:: Canny Canny @@ -146,7 +144,7 @@ cornerSubPix The function iterates to find the sub-pixel accurate location of corners, or radial saddle points, as shown in on the picture below. -.. image:: ../../pics/cornersubpix.png +.. image:: pics/cornersubpix.png Sub-pixel accurate corner locator is based on the observation that every vector from the center :math:`q` to a point @@ -408,11 +406,11 @@ Matas00 This is the sample picture the function parameters have been tuned for: -.. image:: ../../pics/building.jpg +.. image:: pics/building.jpg And this is the output of the above program in the case of probabilistic Hough transform -.. image:: ../../pics/houghp.png +.. image:: pics/houghp.png .. index:: preCornerDetect diff --git a/modules/imgproc/doc/filtering.rst b/modules/imgproc/doc/filtering.rst index a8e4a5e725..339bd75edc 100644 --- a/modules/imgproc/doc/filtering.rst +++ b/modules/imgproc/doc/filtering.rst @@ -1,8 +1,6 @@ Image Filtering =============== -.. highlight:: cpp - Functions and classes described in this section are used to perform various linear or non-linear filtering operations on 2D images (represented as :func:`Mat` 's), that is, for each pixel location :math:`(x,y)` in the source image some its (normally rectangular) neighborhood is considered and used to compute the response. In case of a linear filter it is a weighted sum of pixel values, in case of morphological operations it is the minimum or maximum etc. The computed response is stored to the destination image at the same location diff --git a/modules/imgproc/doc/geometric_transformations.rst b/modules/imgproc/doc/geometric_transformations.rst index d6fff0c782..e7dac8c0b6 100644 --- a/modules/imgproc/doc/geometric_transformations.rst +++ b/modules/imgproc/doc/geometric_transformations.rst @@ -1,8 +1,6 @@ Geometric Image Transformations =============================== -.. highlight:: cpp - The functions in this section perform various geometrical transformations of 2D images. That is, they do not change the image content, but deform the pixel grid, and map this deformed grid to the destination image. In fact, to avoid sampling artifacts, the mapping is done in the reverse order, from destination to the source. That is, for each pixel :math:`(x, y)` of the destination image, the functions compute coordinates of the corresponding "donor" pixel in the source image and copy the pixel value, that is: diff --git a/modules/imgproc/doc/histograms.rst b/modules/imgproc/doc/histograms.rst index fbbe0fc7a7..3bf6080d8f 100644 --- a/modules/imgproc/doc/histograms.rst +++ b/modules/imgproc/doc/histograms.rst @@ -1,8 +1,6 @@ Histograms ========== -.. highlight:: cpp - .. index:: calcHist calcHist diff --git a/modules/imgproc/doc/imgproc.rst b/modules/imgproc/doc/imgproc.rst index af9aa11b20..acaebc4753 100644 --- a/modules/imgproc/doc/imgproc.rst +++ b/modules/imgproc/doc/imgproc.rst @@ -2,6 +2,8 @@ imgproc. Image Processing ************************* +.. highlight:: cpp + .. toctree:: :maxdepth: 2 @@ -10,7 +12,6 @@ imgproc. Image Processing miscellaneous_transformations histograms structural_analysis_and_shape_descriptors - planar_subdivisions motion_analysis_and_object_tracking feature_detection object_detection diff --git a/modules/imgproc/doc/miscellaneous_transformations.rst b/modules/imgproc/doc/miscellaneous_transformations.rst index 629a0964a4..c811488096 100644 --- a/modules/imgproc/doc/miscellaneous_transformations.rst +++ b/modules/imgproc/doc/miscellaneous_transformations.rst @@ -1,8 +1,6 @@ Miscellaneous Image Transformations =================================== -.. highlight:: cpp - .. index:: adaptiveThreshold adaptiveThreshold @@ -616,7 +614,7 @@ As a practical example, the next figure shows the calculation of the integral of \begin{center} -.. image:: ../../pics/integral.png +.. image:: pics/integral.png \end{center} @@ -682,7 +680,7 @@ value using Otsu's algorithm and uses it instead of the specified ``thresh`` . The function returns the computed threshold value. Currently, Otsu's method is implemented only for 8-bit images. -.. image:: ../../pics/threshold.png +.. image:: pics/threshold.png See also: :func:`adaptiveThreshold`,:func:`findContours`,:func:`compare`,:func:`min`,:func:`max` diff --git a/modules/imgproc/doc/motion_analysis_and_object_tracking.rst b/modules/imgproc/doc/motion_analysis_and_object_tracking.rst index a4688e90ec..d8d3f701f1 100644 --- a/modules/imgproc/doc/motion_analysis_and_object_tracking.rst +++ b/modules/imgproc/doc/motion_analysis_and_object_tracking.rst @@ -1,8 +1,6 @@ Motion Analysis and Object Tracking =================================== -.. highlight:: cpp - .. index:: accumulate accumulate diff --git a/modules/imgproc/doc/object_detection.rst b/modules/imgproc/doc/object_detection.rst index 3739b8af80..a4cabfec71 100644 --- a/modules/imgproc/doc/object_detection.rst +++ b/modules/imgproc/doc/object_detection.rst @@ -1,8 +1,6 @@ Object Detection ================ -.. highlight:: cpp - .. index:: matchTemplate matchTemplate diff --git a/modules/imgproc/doc/pics/backprojectpatch.png b/modules/imgproc/doc/pics/backprojectpatch.png new file mode 100644 index 0000000000..11dfb29372 Binary files /dev/null and b/modules/imgproc/doc/pics/backprojectpatch.png differ diff --git a/modules/imgproc/doc/pics/boundingrect.png b/modules/imgproc/doc/pics/boundingrect.png new file mode 100644 index 0000000000..3ccfe4b533 Binary files /dev/null and b/modules/imgproc/doc/pics/boundingrect.png differ diff --git a/modules/imgproc/doc/pics/building.jpg b/modules/imgproc/doc/pics/building.jpg new file mode 100644 index 0000000000..6056492f2f Binary files /dev/null and b/modules/imgproc/doc/pics/building.jpg differ diff --git a/modules/imgproc/doc/pics/contoursecarea.png b/modules/imgproc/doc/pics/contoursecarea.png new file mode 100644 index 0000000000..de67e28047 Binary files /dev/null and b/modules/imgproc/doc/pics/contoursecarea.png differ diff --git a/modules/imgproc/doc/pics/cornersubpix.png b/modules/imgproc/doc/pics/cornersubpix.png new file mode 100644 index 0000000000..b86febbce3 Binary files /dev/null and b/modules/imgproc/doc/pics/cornersubpix.png differ diff --git a/modules/imgproc/doc/pics/defects.png b/modules/imgproc/doc/pics/defects.png new file mode 100644 index 0000000000..2ec45ac0bb Binary files /dev/null and b/modules/imgproc/doc/pics/defects.png differ diff --git a/modules/imgproc/doc/pics/houghp.png b/modules/imgproc/doc/pics/houghp.png new file mode 100644 index 0000000000..18d2096e55 Binary files /dev/null and b/modules/imgproc/doc/pics/houghp.png differ diff --git a/modules/imgproc/doc/pics/integral.png b/modules/imgproc/doc/pics/integral.png new file mode 100644 index 0000000000..97a69c625f Binary files /dev/null and b/modules/imgproc/doc/pics/integral.png differ diff --git a/modules/imgproc/doc/pics/inv_logpolar.jpg b/modules/imgproc/doc/pics/inv_logpolar.jpg new file mode 100644 index 0000000000..d76f067d2a Binary files /dev/null and b/modules/imgproc/doc/pics/inv_logpolar.jpg differ diff --git a/modules/imgproc/doc/pics/logpolar.jpg b/modules/imgproc/doc/pics/logpolar.jpg new file mode 100644 index 0000000000..6c062e765e Binary files /dev/null and b/modules/imgproc/doc/pics/logpolar.jpg differ diff --git a/modules/imgproc/doc/pics/minareabox.png b/modules/imgproc/doc/pics/minareabox.png new file mode 100644 index 0000000000..7c10da16e6 Binary files /dev/null and b/modules/imgproc/doc/pics/minareabox.png differ diff --git a/modules/imgproc/doc/pics/pointpolygon.png b/modules/imgproc/doc/pics/pointpolygon.png new file mode 100644 index 0000000000..de49031a3a Binary files /dev/null and b/modules/imgproc/doc/pics/pointpolygon.png differ diff --git a/modules/imgproc/doc/pics/quadedge.png b/modules/imgproc/doc/pics/quadedge.png new file mode 100644 index 0000000000..2fc6c2bfcf Binary files /dev/null and b/modules/imgproc/doc/pics/quadedge.png differ diff --git a/modules/imgproc/doc/pics/subdiv.png b/modules/imgproc/doc/pics/subdiv.png new file mode 100644 index 0000000000..21026e5eeb Binary files /dev/null and b/modules/imgproc/doc/pics/subdiv.png differ diff --git a/modules/imgproc/doc/pics/threshold.png b/modules/imgproc/doc/pics/threshold.png new file mode 100644 index 0000000000..2e1bfdf314 Binary files /dev/null and b/modules/imgproc/doc/pics/threshold.png differ diff --git a/modules/imgproc/doc/structural_analysis_and_shape_descriptors.rst b/modules/imgproc/doc/structural_analysis_and_shape_descriptors.rst index 645525647a..1aad937478 100644 --- a/modules/imgproc/doc/structural_analysis_and_shape_descriptors.rst +++ b/modules/imgproc/doc/structural_analysis_and_shape_descriptors.rst @@ -1,8 +1,6 @@ Structural Analysis and Shape Descriptors ========================================= -.. highlight:: cpp - .. index:: moments moments @@ -572,5 +570,5 @@ edge. Here is the sample output of the function, where each image pixel is tested against the contour. -.. image:: ../../pics/pointpolygon.png +.. image:: pics/pointpolygon.png diff --git a/modules/index.rst b/modules/index.rst index 508c104213..a718990042 100644 --- a/modules/index.rst +++ b/modules/index.rst @@ -8,6 +8,8 @@ Welcome to opencvstd's documentation! Contents: +.. highlight:: cpp + .. toctree:: :maxdepth: 2 diff --git a/modules/ml/doc/boosting.rst b/modules/ml/doc/boosting.rst index 32de650e98..b75493fc38 100644 --- a/modules/ml/doc/boosting.rst +++ b/modules/ml/doc/boosting.rst @@ -1,8 +1,6 @@ Boosting ======== -.. highlight:: cpp - A common machine learning task is supervised learning. In supervised learning, the goal is to learn the functional relationship :math:`F: y = F(x)` between the input :math:`x` and the output diff --git a/modules/ml/doc/decision_trees.rst b/modules/ml/doc/decision_trees.rst index bddf718018..5ad3ce11ab 100644 --- a/modules/ml/doc/decision_trees.rst +++ b/modules/ml/doc/decision_trees.rst @@ -1,8 +1,6 @@ Decision Trees ============== -.. highlight:: cpp - The ML classes discussed in this section implement Classification And Regression Tree algorithms, which are described in `[Breiman84] <#paper_Breiman84>`_ . diff --git a/modules/ml/doc/expectation_maximization.rst b/modules/ml/doc/expectation_maximization.rst index 17a1dcfc04..6ed2e6700e 100644 --- a/modules/ml/doc/expectation_maximization.rst +++ b/modules/ml/doc/expectation_maximization.rst @@ -1,8 +1,6 @@ Expectation-Maximization ======================== -.. highlight:: cpp - The EM (Expectation-Maximization) algorithm estimates the parameters of the multivariate probability density function in the form of a Gaussian mixture distribution with a specified number of mixtures. Consider the set of the feature vectors diff --git a/modules/ml/doc/k_nearest_neighbors.rst b/modules/ml/doc/k_nearest_neighbors.rst index d748c37b8c..de42ffb51a 100644 --- a/modules/ml/doc/k_nearest_neighbors.rst +++ b/modules/ml/doc/k_nearest_neighbors.rst @@ -1,8 +1,6 @@ K Nearest Neighbors =================== -.. highlight:: cpp - The algorithm caches all of the training samples, and predicts the response for a new sample by analyzing a certain number ( **K** ) of the nearest neighbors of the sample (using voting, calculating weighted sum etc.) The method is sometimes referred to as "learning by example", because for prediction it looks for the feature vector with a known response that is closest to the given vector. diff --git a/modules/ml/doc/neural_networks.rst b/modules/ml/doc/neural_networks.rst index 2ec6021c2e..4e6fd0fc08 100644 --- a/modules/ml/doc/neural_networks.rst +++ b/modules/ml/doc/neural_networks.rst @@ -1,16 +1,14 @@ Neural Networks =============== -.. highlight:: cpp - ML implements feed-forward artificial neural networks, more particularly, multi-layer perceptrons (MLP), the most commonly used type of neural networks. MLP consists of the input layer, output layer and one or more hidden layers. Each layer of MLP includes one or more neurons that are directionally linked with the neurons from the previous and the next layer. Here is an example of a 3-layer perceptron with 3 inputs, 2 outputs and the hidden layer including 5 neurons: -.. image:: ../../pics/mlp_.png +.. image:: pics/mlp.png All the neurons in MLP are similar. Each of them has several input links (i.e. it takes the output values from several neurons in the previous layer on input) and several output links (i.e. it passes the response to several neurons in the next layer). The values retrieved from the previous layer are summed with certain weights, individual for each neuron, plus the bias term, and the sum is transformed using the activation function :math:`f` that may be also different for different neurons. Here is the picture: -.. image:: ../../pics/neuron_model.png +.. image:: pics/neuron_model.png In other words, given the outputs :math:`x_j` of the layer @@ -36,7 +34,7 @@ Different activation functions may be used, ML implements 3 standard ones: :math:`f(x)=\beta*(1-e^{-\alpha x})/(1+e^{-\alpha x}` ), the default choice for MLP; the standard sigmoid with :math:`\beta =1, \alpha =1` is shown below: - .. image:: ../../pics/sigmoid_bipolar.png + .. image:: pics/sigmoid_bipolar.png * Gaussian function ( ``CvANN_MLP::GAUSSIAN`` ): diff --git a/modules/ml/doc/normal_bayes_classifier.rst b/modules/ml/doc/normal_bayes_classifier.rst index c4ea513a63..a5dc24aaca 100644 --- a/modules/ml/doc/normal_bayes_classifier.rst +++ b/modules/ml/doc/normal_bayes_classifier.rst @@ -9,8 +9,6 @@ This is a simple classification model assuming that feature vectors from each cl .. index:: CvNormalBayesClassifier -.. _CvNormalBayesClassifier: - CvNormalBayesClassifier ----------------------- .. c:type:: CvNormalBayesClassifier diff --git a/modules/ml/doc/pics/mlp.png b/modules/ml/doc/pics/mlp.png new file mode 100644 index 0000000000..ce3392c454 Binary files /dev/null and b/modules/ml/doc/pics/mlp.png differ diff --git a/modules/ml/doc/pics/neuron_model.png b/modules/ml/doc/pics/neuron_model.png new file mode 100644 index 0000000000..635a531804 Binary files /dev/null and b/modules/ml/doc/pics/neuron_model.png differ diff --git a/modules/ml/doc/pics/sigmoid_bipolar.png b/modules/ml/doc/pics/sigmoid_bipolar.png new file mode 100644 index 0000000000..d94a85031d Binary files /dev/null and b/modules/ml/doc/pics/sigmoid_bipolar.png differ diff --git a/modules/ml/doc/statistical_models.rst b/modules/ml/doc/statistical_models.rst index f897f98821..b99c620c46 100644 --- a/modules/ml/doc/statistical_models.rst +++ b/modules/ml/doc/statistical_models.rst @@ -5,8 +5,6 @@ Statistical Models .. index:: CvStatModel -.. _CvStatModel: - CvStatModel ----------- .. c:type:: CvStatModel diff --git a/modules/objdetect/doc/cascade_classification.rst b/modules/objdetect/doc/cascade_classification.rst index 207da0890d..3a329d62de 100644 --- a/modules/objdetect/doc/cascade_classification.rst +++ b/modules/objdetect/doc/cascade_classification.rst @@ -5,8 +5,6 @@ Cascade Classification .. index:: FeatureEvaluator -.. _FeatureEvaluator: - FeatureEvaluator ---------------- .. c:type:: FeatureEvaluator diff --git a/modules/objdetect/doc/objdetect.rst b/modules/objdetect/doc/objdetect.rst index c1e3eb4c5c..c00e64e59d 100644 --- a/modules/objdetect/doc/objdetect.rst +++ b/modules/objdetect/doc/objdetect.rst @@ -2,6 +2,8 @@ objdetect. Object Detection *************************** +.. highlight:: cpp + .. toctree:: :maxdepth: 2