State object for calculating various image moments. More...
#include <cvb/foundation/moments.hpp>
Public Member Functions | |
| ImageMoments (const ImagePlane &imagePlane, Rect< int > aoi, MomentsCalculation preference=MomentsCalculation::FavorNone) | |
| Calculate the moments on the input ImagePlane and area of interest. | |
| ImageMoments (const ImagePlane &imagePlane, MomentsCalculation preference=MomentsCalculation::FavorNone) | |
| Calculate the moments on the input imagePlane. | |
| ImageMoments (ImageMoments &&) noexcept=default | |
| Move constructor. | |
| ImageMoments & | operator= (ImageMoments &&) noexcept=default |
| Move assignment operator. | |
| MomentsCalculation | CalculationPreference () const noexcept |
| The preference of speed versus accuracy chosen when this object was created. | |
| void * | Handle () const noexcept |
| Classic API IMGMOMENTS handle. | |
| double | SpatialMoment (MomentsOrder xOrder, MomentsOrder yOrder, MomentsNormalization normalization, Point2D< int > offset) |
| Get one of the spatial image moments. | |
| double | SpatialMoment (MomentsOrder xOrder, MomentsOrder yOrder, MomentsNormalization normalization) |
| Get one of the spatial image moments. | |
| double | CentralMoment (MomentsOrder xOrder, MomentsOrder yOrder, MomentsNormalization normalization) |
| Get one of the central image moments. | |
| HuMoments | HuMoments () |
| Get the seven Hu moments of the image. | |
Static Public Member Functions | |
| static std::unique_ptr< ImageMoments > | Calculate (const ImagePlane &imagePlane, Rect< int > aoi, MomentsCalculation preference=MomentsCalculation::FavorNone) |
| Calculate the moments on the input imagePlane and aoi. | |
| static std::unique_ptr< ImageMoments > | Calculate (const ImagePlane &imagePlane, MomentsCalculation preference=MomentsCalculation::FavorNone) |
| Calculate the moments on the input imagePlane. | |
State object for calculating various image moments.
|
inline |
Calculate the moments on the input ImagePlane and area of interest.
| [in] | imagePlane | Plane to calculate the moments. |
| [in] | aoi | Area of interest to calculate the moments in. |
| [in] | preference | Speed or accuracy. |
| Any | exception derived from std::exception including CvbException. |
|
inline |
Calculate the moments on the input imagePlane.
| [in] | imagePlane | Plane on which to calculate the moments. |
| [in] | preference | Speed or accuracy. |
| Any | exception derived from std::exception including CvbException. |
|
inlinestatic |
Calculate the moments on the input imagePlane.
| [in] | imagePlane | Plane on which to calculate the moments. |
| [in] | preference | Speed or accuracy. |
| Does | not throw any exception. |
|
inlinestatic |
Calculate the moments on the input imagePlane and aoi.
| [in] | imagePlane | Plane on which to calculate the moments. |
| [in] | aoi | Area of interest to calculate the moments. |
| [in] | preference | Speed or accuracy. |
| Does | not throw any exception. |
|
inlinenoexcept |
The preference of speed versus accuracy chosen when this object was created.
| Does | not throw any exception. |
|
inline |
Get one of the central image moments.
| [in] | xOrder | X order of the moment to retrieve. |
| [in] | yOrder | Y order of the moment to retrieve. |
| [in] | normalization | Whether or not to normalize. |
| Any | exception derived from std::exception including CvbException. |
|
inlinenoexcept |
Classic API IMGMOMENTS handle.
| Does | not throw any exception. |
It is normally not necessary to work with this handle.
Get the seven Hu moments of the image.
| Any | exception derived from std::exception including CvbException. |
|
inline |
Get one of the spatial image moments.
| [in] | xOrder | X order of the moment to retrieve. |
| [in] | yOrder | Y order of the moment to retrieve. |
| [in] | normalization | Whether or not to normalize. |
| Any | exception derived from std::exception including CvbException. |
This overload automatically uses the offset used in creating this object.
|
inline |
Get one of the spatial image moments.
| [in] | xOrder | X order of the moment to retrieve. |
| [in] | yOrder | Y order of the moment to retrieve. |
| [in] | normalization | Whether or not to normalize. |
| [in] | offset | Offset of the moments. |
| Any | exception derived from std::exception including CvbException. |