Blob counter based on recursion.
Namespace:
AForge.ImagingAssembly: AForge.Imaging (in AForge.Imaging.dll) Version: 2.2.5.0 (2.2.5.0)
Syntax
| C# |
|---|
public class RecursiveBlobCounter : BlobCounterBase |
Remarks
The class counts and extracts stand alone objects in images using recursive version of connected components labeling algorithm.
For blobs’ searching the class supports 8 bpp indexed grayscale images and 24/32 bpp color images. See documentation about BlobCounterBase for information about which pixel formats are supported for extraction of blobs.
Sample usage:
// create an instance of blob counter algorithm RecursiveBlobCounter bc = new RecursiveBlobCounter( ); // process binary image bc.ProcessImage( image ); Rectangle[] rects = bc.GetObjectsRectangles( ); // process blobs foreach ( Rectangle rect in rects ) { // ... }