mirror of
https://github.com/opencv/opencv.git
synced 2026-07-29 23:33:05 +04:00
Copied some comments from wiki to the main documentation
This commit is contained in:
@@ -1781,6 +1781,8 @@ Difference norm between two projections is the maximal distance between correspo
|
||||
``criteria.epsilon``
|
||||
serves to stop the algorithm if the difference is small.
|
||||
|
||||
An example of using ``cvPOSIT`` and ``cvCreatePOSITObject`` is available at http://opencv.willowgarage.com/wiki/Posit
|
||||
|
||||
|
||||
.. index:: ProjectPoints2
|
||||
|
||||
|
||||
@@ -7234,7 +7234,7 @@ mSet
|
||||
|
||||
.. cfunction:: void cvmSet(CvMat* mat, int row, int col, double value)
|
||||
|
||||
Returns a specific element of a single-channel floating-point matrix.
|
||||
Sets a specific element of a single-channel floating-point matrix.
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -413,10 +413,8 @@ value if all of the corners are found and they are placed
|
||||
in a certain order (row by row, left to right in every row). Otherwise, if the function fails to find all the corners or reorder
|
||||
them, it returns 0. For example, a regular chessboard has 8 x 8
|
||||
squares and 7 x 7 internal corners, that is, points where the black
|
||||
squares touch each other. The detected coordinates are approximate,
|
||||
and to determine their position more accurately, you may use
|
||||
the function
|
||||
:ref:`cornerSubPix`.
|
||||
squares touch each other. The detected coordinates are approximate so the function calls :ref:`cornerSubPix` internally to determine their position more accurately.
|
||||
You also may use the function :ref:`cornerSubPix` with different parameters if returned coordinates are not accurate enough.
|
||||
|
||||
Sample usage of detecting and drawing chessboard corners: ::
|
||||
|
||||
@@ -628,7 +626,7 @@ findHomography
|
||||
|
||||
.. math::
|
||||
|
||||
\| \texttt{dstPoints} _i - \texttt{convertPointsHomogeneous} ( \texttt{H} \texttt{srcPoints} _i) \| > \texttt{ransacReprojThreshold}
|
||||
\| \texttt{dstPoints} _i - \texttt{convertPointsHomogeneous} ( \texttt{H} * \texttt{srcPoints} _i) \| > \texttt{ransacReprojThreshold}
|
||||
|
||||
then the point :math:`i` is considered an outlier. If ``srcPoints`` and ``dstPoints`` are measured in pixels, it usually makes sense to set this parameter somewhere in the range of 1 to 10.
|
||||
|
||||
|
||||
@@ -46,7 +46,7 @@ Maximally stable extremal region extractor. ::
|
||||
};
|
||||
|
||||
The class encapsulates all the parameters of the MSER extraction algorithm (see
|
||||
http://en.wikipedia.org/wiki/Maximally_stable_extremal_regions).
|
||||
http://en.wikipedia.org/wiki/Maximally_stable_extremal_regions). Also see http://opencv.willowgarage.com/wiki/documentation/cpp/features2d/MSER for usefull comments and parameters description.
|
||||
|
||||
.. index:: StarDetector
|
||||
|
||||
|
||||
@@ -366,5 +366,6 @@ Video writer class ::
|
||||
...
|
||||
};
|
||||
|
||||
For more detailed description see http://opencv.willowgarage.com/wiki/documentation/cpp/highgui/VideoWriter
|
||||
..
|
||||
|
||||
|
||||
@@ -124,7 +124,7 @@ Qt-specific details:
|
||||
|
||||
::
|
||||
|
||||
namedWindow( ``myWindow'', ``CV_WINDOW_NORMAL`` textbar ``CV_GUI_NORMAL`` );
|
||||
namedWindow( "myWindow", CV_WINDOW_NORMAL | CV_GUI_NORMAL );
|
||||
|
||||
..
|
||||
|
||||
@@ -194,7 +194,7 @@ waitKey
|
||||
:param delay: Delay in milliseconds. 0 is the special value that means "forever".
|
||||
|
||||
The function ``waitKey`` waits for a key event infinitely (when
|
||||
:math:`\texttt{delay}\leq 0` ) or for ``delay`` milliseconds, when it is positive. It returns the code of the pressed key or -1 if no key was pressed before the specified time had elapsed.
|
||||
:math:`\texttt{delay}\leq 0` ) or for ``delay`` milliseconds, when it is positive. Since the OS has a minimum time between switching threads, the function will not wait exactly ``delay`` ms, it will wait at least ``delay`` ms, depending on what else is running on your computer at that time. It returns the code of the pressed key or -1 if no key was pressed before the specified time had elapsed.
|
||||
|
||||
**Notes:**
|
||||
|
||||
|
||||
@@ -336,7 +336,8 @@ HoughLines
|
||||
:param stn: For the multi-scale Hough transform, it is a divisor for the distance resolution ``theta`` .
|
||||
|
||||
The function implements the standard or standard multi-scale Hough transform algorithm for line detection. See
|
||||
:ocv:func:`HoughLinesP` for the code example.
|
||||
:ocv:func:`HoughLinesP` for the code example. Also see http://homepages.inf.ed.ac.uk/rbf/HIPR2/hough.htm for a good explanation of Hough transform.
|
||||
|
||||
|
||||
.. index:: HoughLinesP
|
||||
|
||||
|
||||
@@ -388,6 +388,14 @@ bilateralFilter
|
||||
|
||||
The function applies bilateral filtering to the input image, as described in
|
||||
http://www.dai.ed.ac.uk/CVonline/LOCAL\_COPIES/MANDUCHI1/Bilateral\_Filtering.html
|
||||
``bilateralFilter`` can do a very good job of reducing unwanted noise while keep edges fairly sharp. However it is very slow compared to most filters.
|
||||
|
||||
*Sigma values*: For simplicity, you can set the 2 sigma values to be the same. If they are small (< 10) then the filter will not have much effect, whereas if they are large (> 150) then they will have a very strong effect, making the image look "cartoonish".
|
||||
|
||||
*Filter size*: Large filters (d > 5) are very slow, so it is recommended to use d=5 for real-time applications, and perhaps d=9 for offline applications that need heavy noise filtering.
|
||||
|
||||
This filter doesn't work inplace.
|
||||
|
||||
|
||||
.. index:: blur
|
||||
|
||||
|
||||
@@ -195,7 +195,7 @@ The function calculates the following matrix:
|
||||
|
||||
.. math::
|
||||
|
||||
\begin{bmatrix} \alpha & \beta & (1- \alpha ) \cdot \texttt{center.x} - \beta \cdot \texttt{center.y} \\ - \beta & \alpha & \beta \cdot \texttt{center.x} - (1- \alpha ) \cdot \texttt{center.y} \end{bmatrix}
|
||||
\begin{bmatrix} \alpha & \beta & (1- \alpha ) \cdot \texttt{center.x} - \beta \cdot \texttt{center.y} \\ - \beta & \alpha & \beta \cdot \texttt{center.x} + (1- \alpha ) \cdot \texttt{center.y} \end{bmatrix}
|
||||
|
||||
where
|
||||
|
||||
@@ -339,6 +339,7 @@ If you want to decimate the image by factor of 2 in each direction, you can call
|
||||
// specify fx and fy and let the function compute the destination image size.
|
||||
resize(src, dst, Size(), 0.5, 0.5, interpolation);
|
||||
|
||||
To shrink an image, it will generally look best with CV_INTER_AREA interpolation, whereas to enlarge an image, it will generally look best with CV_INTER_CUBIC (slow) or CV_INTER_LINEAR (faster but still looks OK).
|
||||
|
||||
See Also:
|
||||
:ocv:func:`warpAffine`,
|
||||
|
||||
@@ -84,6 +84,7 @@ cvtColor
|
||||
|
||||
The function converts an input image from one color
|
||||
space to another. In case of transformation to-from RGB color space, the order of the channels should be specified explicitly (RGB or BGR).
|
||||
Note that the default color format in OpenCV is often referred to as RGB but it is actually BGR (the bytes are reversed). So the first byte in a standard (24-bit) color image will be an 8-bit Blue component, the second byte will be Green and the third byte will be Red. The fourth, fifth and sixth bytes would then be the 2nd pixel (Blue then Green then Red) and so on.
|
||||
|
||||
The conventional ranges for R, G, and B channel values are:
|
||||
|
||||
@@ -103,6 +104,8 @@ But in case of a non-linear transformation, an input RGB image should be normali
|
||||
img *= 1./255;
|
||||
cvtColor(img, img, CV_BGR2Luv);
|
||||
|
||||
If you use ``cvtColor`` with 8-bit images then conversion will have lost some information. For many applications this will not be noticeable but it is recommended to use 32-bit images in applications that need the full range of colors or that convert an image before an operation and then convert back.
|
||||
|
||||
The function can do the following transformations:
|
||||
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user