EasyImage::GravityCenter

Computes the coordinates of the gravity center of an image, i.e. the average coordinates of the pixels above (or on) the threshold.

Namespace: Euresys::Open_eVision

[C++]

void GravityCenter(
   const EROIBW8* sourceImage,
   OEV_UINT32 threshold,
   float& gravityX,
   float& gravityY
)

void GravityCenter(
   const EROIBW16* sourceImage,
   OEV_UINT32 threshold,
   float& gravityX,
   float& gravityY
)

void GravityCenter(
   const EROIBW8* sourceImage,
   const ERegion& region,
   OEV_UINT32 threshold,
   float& gravityX,
   float& gravityY
)

void GravityCenter(
   const EROIBW16* sourceImage,
   const ERegion& region,
   OEV_UINT32 threshold,
   float& gravityX,
   float& gravityY
)

void GravityCenter(
   const EROIBW8* sourceImage,
   const EROIBW8* mask,
   OEV_UINT32 threshold,
   float& gravityX,
   float& gravityY
)

void GravityCenter(
   const EROIBW16* sourceImage,
   const EROIBW8* mask,
   OEV_UINT32 threshold,
   float& gravityX,
   float& gravityY
)

Parameters

sourceImage

Pointer to the source image/ROI.

threshold

Threshold.

gravityX

Reference to the gravity center abscissa.

gravityY

Reference to the gravity center ordinate.

region

Pointer to a region to apply the function only on a particular region in the image.

mask

Pointer to a mask to apply the function only on a particular region in the image. Note: the mask must have the same size as the source image.

EasyImage.GravityCenter

Computes the coordinates of the gravity center of an image, i.e. the average coordinates of the pixels above (or on) the threshold.

Namespace: Euresys.Open_eVision

[C#]

void GravityCenter(
   Euresys.Open_eVision.EROIBW8 sourceImage,
   uint threshold,
   out float gravityX,
   out float gravityY
)

void GravityCenter(
   Euresys.Open_eVision.EROIBW16 sourceImage,
   uint threshold,
   out float gravityX,
   out float gravityY
)

void GravityCenter(
   Euresys.Open_eVision.EROIBW8 sourceImage,
   Euresys.Open_eVision.ERegion region,
   uint threshold,
   out float gravityX,
   out float gravityY
)

void GravityCenter(
   Euresys.Open_eVision.EROIBW16 sourceImage,
   Euresys.Open_eVision.ERegion region,
   uint threshold,
   out float gravityX,
   out float gravityY
)

void GravityCenter(
   Euresys.Open_eVision.EROIBW8 sourceImage,
   Euresys.Open_eVision.EROIBW8 mask,
   uint threshold,
   out float gravityX,
   out float gravityY
)

void GravityCenter(
   Euresys.Open_eVision.EROIBW16 sourceImage,
   Euresys.Open_eVision.EROIBW8 mask,
   uint threshold,
   out float gravityX,
   out float gravityY
)

Parameters

sourceImage

Pointer to the source image/ROI.

threshold

Threshold.

gravityX

Reference to the gravity center abscissa.

gravityY

Reference to the gravity center ordinate.

region

Pointer to a region to apply the function only on a particular region in the image.

mask

Pointer to a mask to apply the function only on a particular region in the image. Note: the mask must have the same size as the source image.