MV Blob Finder DirectShow Filter

The MV Blob Counter filter find a specific blob (object or contour) within an image. The filter contains two filters for blobs. One  filter excludes all blobs outside a minimum and maximum size. The second filter excludes all blobs whose seven hu invariants are outside a minimum and maximum value. Hu invariants are proved to be invariants to the image scale, rotation, and reflection except the seventh one, whose sign is changed by reflection. If more than one blob is found within the image the filter use the largest blob.

The MV Blob Finder filter calculates some blob characteristics like angle, perimeter, area, minimum bounding rect, upright bounding rect, spatial and central moments and hu invariants. Additionally the filter calculates the convex hull for the blob and reduce contour complexity with an approximation algorithm. Use these two options to optimise the blob finding function.

 

File: blobfinder.ax
CLSID: CLSID_MVBlobFinder

 

Supported Interfaces

IMVBlobFinder

IMVBlobFinder2

IMVBlobFinder3

IMVBlobPreProcessing

IMVBlobPostProcessing

IMVRegionOfInterest

IMVFilterData

IMVAbout

IMVFilterInfo

 

Supported COM Events

The filter supports following events through the IMVFilterEvents interface. Look at the filter events page for more information.

Event

Value

Description
MV_ALGORITHM_START_EVENT

0

A filter starts processing a video frame or sample.
MV_ALGORITHM_END_EVENT

1

A filter finishes processing a video frame or sample.

 

Supported I/O Pins

I/O Pin Corresponding method Discription
Threshold In
[uint8]
IMVBlobPreProcessing::put_SegmentationThreshold Segmentation threshold.
Angle Out
[double]
IMVBlobFinder::get_Angle Outputs the angle of a found blob within the current image.
Object Found
[BOOL]
IMVBlobFinder::get_ObjectFound Signals a found blob within the current image.
Center X
[double] [uint16]
IMVBlobFinder2::GetXCenterOfMass Outputs the horizontal position of a found blob.
Center Y
[double] [uint16]
IMVBlobFinder2::GetYCenterOfMass Outputs the vertical position of a found blob.

 

MV Blob Finder Property Pages

Uses the IMVBlobFinder configuration interface.

MontiVision Blob Finder DirectShow Filter Property Page

External Use only external contours. All contours (blobs) within an other blob are ignored.
List All blobs are arranged in on list.
Two level The blobs are arranged into a two level list. All external blobs are in the first level. All other blobs are in the second level. The filter counts all first level blobs.
Tree Same as Two level option, but internal all blobs are arranged in a tree.
Draw Contour Draw blob contour into the output image.
Use convex hull Use the convex hull.
use approximate contour Use an approximation algorithm to reduce the contour complexity.
accuracy Accuracy value for the approximation algorithm.
Position and Angle Select the base for position and angle calculation and output.
min bounding rect Enable calculating and drawing the minimum bounding rect into the output image.
upright bounding rect Enable calculating and drawing the upright bounding rect into the output image.
angle Enable calculating and drawing the angle into the output image.
use min bounding rect angle Use the angle from the min bounding rect for the angle value.
area Enable calculating and drawing the area into the output image.
perimeter Enable calculating and drawing the perimeter into the output image.
hu moments Enable calculating and drawing hu invariants into the output image.
x/y Position for output text within the output image

 

MontiVision Blob Finder DirectShow Filter Contour Filter Property Page

enable contour filter Enable the contour filter
contour size Enable size contour filter
width Minimum and maximum value for the contour width.
height Minimum and maximum value for the contour height.
hu invariants Enable hu invariants contour filter.
hu 1 to hu 7 Minimum and maximum value for the seven hu invariants.

 

MontiVision Blob Finder DirectShow Filter Pre-Processing Property Page

Segmentation Threshold Threashold value for image segmentation.
Draw Segmentation The output image cotains the result after segmentation and edge detection.
Edge Detection Select the algorithm for edge detection.
Blob Type Find dark or bright blobs.