OpenCV453
|
struct returned by cv::moments [詳解]
#include <types.hpp>
公開メンバ関数 | |
Moments () | |
the default constructor | |
Moments (double m00, double m10, double m01, double m20, double m11, double m02, double m30, double m21, double m12, double m03) | |
the full constructor | |
struct returned by cv::moments
The spatial moments are computed as:
The central moments are computed as:
where is the mass center:
The normalized central moments are computed as:
The moments of a contour are defined in the same way but computed using the Green's formula (see http://en.wikipedia.org/wiki/Green_theorem). So, due to a limited raster resolution, the moments computed for a contour are slightly different from the moments computed for the same rasterized contour.