Calculates spatial and central moments up to the third order and writes them to moments. The moments may be used then to calculate gravity center of the shape, its area, main axises and various shape characeteristics including 7 Hu invariants.

Namespace:  Emgu.CV
Assembly:  Emgu.CV (in Emgu.CV.dll) Version: 2.1.0.649 (2.1.0.649)

Syntax

         
 C#  Visual Basic  Visual C++ 
public MCvMoments GetMoments(
	bool binary
)
Public Function GetMoments ( _
	binary As Boolean _
) As MCvMoments
public:
MCvMoments GetMoments(
	bool binary
)

Parameters

binary
Boolean
If the flag is true, all the zero pixel values are treated as zeroes, all the others are treated as 1's

Return Value

spatial and central moments up to the third order

See Also