-
Notifications
You must be signed in to change notification settings - Fork 2
Vchecker
This function block offers two distinct operation groups:
- Labeling: Finds regions in a binary (black/white) input image and calculates labels as well as bounding rectangles around them.
- Image moments: Calculates a number of image moments from a labeled binary input image. Already present results are reused, i.e. if an image moment requires the object perimeter as in input variable, it does not unnecessarily recalculate it if this value has already been calculated.
Implemented by Martin Kurmann and Sandro Gort as part of their Bachelor Thesis. Many thanks for their contribution!
Oscar modules:
- DSPL.
Calculates the perimeter of an object in the given image region.
Arguments:
- uint8* pBw: Image region to analyze.
- uint32 width: Width of the image region.
- uint32 height: Height of the image region.
- struct G_BOUNDINGBOX *bb: Resulting bounding boxes around the objects and their label.
- void
Calculates the perimeter of an object in the given image region.
Arguments:
- uint8* pBw: Image region to analyze.
- uint32 width: Width of the image region.
- uint32 height: Height of the image region.
- struct G_DESCRIPTOR *descr: Object descriptor where the calculated perimeter will be stored.
- struct G_BOUNDINGBOX *bb: Bounding box in the image region containing the object and its label.
- void
Calculates the area of an object in the give image region.
Arguments:
- uint8* pBw: Image region to analyze.
- uint32 width: Width of the image region.
- uint32 height: Height of the image region.
- struct G_DESCRIPTOR *descr: Object descriptor where the calculated area will be stored.
- struct G_BOUNDINGBOX *bb: Bounding box in the image region containing the object and its label.
- void
Calculates the compactness (Perimeter^2/Area) of an object in the given image region.
Arguments:
- uint8* pBw: Image region to analyze.
- uint32 width: Width of the image region.
- uint32 height: Height of the image region.
- struct G_DESCRIPTOR *descr: Object descriptor where the calculated compactness will be stored.
- struct G_BOUNDINGBOX *bb: Bounding box in the image region containing the object and its label.
- void
Calculates the mass centre of an object in the given image region.
Arguments:
- uint8* pBw: Image region to analyze.
- uint32 width: Width of the image region.
- uint32 height: Height of the image region.
- struct G_DESCRIPTOR *descr: Object descriptor where the calculated mass centre will be stored.
- struct G_BOUNDINGBOX *bb: Bounding box in the image region containing the object and its label.
- void
Calculates the mass centre of the contour of an object in the given image region.
Arguments:
- uint8* pBw: Image region to analyze.
- uint32 width: Width of the image region.
- uint32 height: Height of the image region.
- struct G_DESCRIPTOR *descr: Object descriptor where the calculated mass centre will be stored.
- struct G_BOUNDINGBOX *bb: Bounding box in the image region containing the object and its label.
- void
Calculates the Fourier spectrum of the contour of an object in the given image region.
Arguments:
- uint8* pBw: Image region to analyze.
- uint32 width: Width of the image region.
- uint32 height: Height of the image region.
- struct G_DESCRIPTOR *descr: Object descriptor where the calculated Fourier Magnitude will be stored.
- struct G_BOUNDINGBOX *bb: Bounding box in the image region containing the object and its label.
- void
Calculates the number of holes of an object in the given image region.
Arguments:
- uint8* pBw: Image region to analyze.
- uint32 width: Width of the image region.
- uint32 height: Height of the image region.
- struct G_DESCRIPTOR *descr: Object descriptor where the calculated number of holes will be stored.
- struct G_BOUNDINGBOX *bb: Bounding box in the image region containing the object and its label.
- void
Calculates the mean distance of the contour to the balance point of an object in the given image region.
Arguments:
- uint8* pBw: Image region to analyze.
- uint32 width: Width of the image region.
- uint32 height: Height of the image region.
- struct G_DESCRIPTOR *descr: Object descriptor where the calculated distance will be stored.
- struct G_BOUNDINGBOX *bb: Bounding box in the image region containing the object and its label.
- void