An example using the cv::linearPolar and cv::logPolar operations
An example using the cv::linearPolar and cv::logPolar operations
*/
*/
/** @brief Remaps an image to log-polar space.
/** @brief Remaps an image to semilog-polar coordinates space.
Transform the source image using the following transformation (See @ref polar_remaps_reference_image "Polar remaps reference image"):
\f[\begin{array}{l}
dst( \rho , \phi ) = src(x,y) \\
dst.size() \leftarrow src.size()
\end{array}\f]
transforms the source image using the following transformation:
\f[dst( \phi , \rho ) = src(x,y)\f]
where
where
\f[\rho = M \cdot \log{\sqrt{x^2 + y^2}} , \phi =atan(y/x)\f]
\f[\begin{array}{l}
I = (dx,dy) = (x - center.x,y - center.y) \\
\rho = M \cdot log_e(\texttt{magnitude} (I)) ,\\
\phi = Ky \cdot \texttt{angle} (I)_{0..360 deg} \\
\end{array}\f]
The function emulates the human "foveal" vision and can be used for fast scale and
and
rotation-invariant template matching, for object tracking and so forth. The function can not operate
\f[\begin{array}{l}
in-place.
M = src.cols / log_e(maxRadius) \\
Ky = src.rows / 360 \\
\end{array}\f]
The function emulates the human "foveal" vision and can be used for fast scale and
rotation-invariant template matching, for object tracking and so forth.
@param src Source image
@param src Source image
@param dst Destination image
@param dst Destination image. It will have same size and type as src.
@param center The transformation center; where the output precision is maximal
@param center The transformation center; where the output precision is maximal
@param M Magnitude scale parameter.
@param M Magnitude scale parameter. It determines the radius of the bounding circle to transform too.
@param flags A combination of interpolation methods, see cv::InterpolationFlags
@param flags A combination of interpolation methods, see cv::InterpolationFlags
*/
@note
- The function can not operate in-place.
- To calculate magnitude and angle in degrees @ref cv::cartToPolar is used internally thus angles are measured from 0 to 360 with accuracy about 0.3 degrees.
@param maxRadius The radius of the bounding circle to transform. It determines the inverse magnitude scale parameter too.
@param flags A combination of interpolation methods, see cv::InterpolationFlags
@param flags A combination of interpolation methods, see cv::InterpolationFlags
*/
@note
- The function can not operate in-place.
- To calculate magnitude and angle in degrees @ref cv::cartToPolar is used internally thus angles are measured from 0 to 360 with accuracy about 0.3 degrees.