C# Class Accord.Imaging.Filters.ExtractBiggestBlob

Extract the biggest blob from image.

The filter locates the biggest blob in the source image and extracts it. The filter also can use the source image for the biggest blob's location only, but extract it from another image, which is set using OriginalImage property. The original image usually is the source of the processed image.

The filter accepts 8 bpp grayscale images and 24/32 color images for processing as source image passed to Apply( Bitmap ) method and also for the OriginalImage.

Sample usage:

// create filter var filter = new ExtractBiggestBlob(); // apply the filter Bitmap biggestBlobsImage = filter.Apply(image);

Initial image:

Result image:

Inheritance: IFilter, IFilterInformation
Mostrar archivo Open project: accord-net/framework

Public Methods

Method Description
Apply ( Bitmap image ) : Bitmap

Apply filter to an image.

Apply ( BitmapData imageData ) : Bitmap

Apply filter to an image.

Apply ( UnmanagedImage image ) : UnmanagedImage

Apply filter to an image (not implemented).

Apply ( UnmanagedImage sourceImage, UnmanagedImage destinationImage ) : void

Apply filter to an image (not implemented).

Method Details

Apply() public method

Apply filter to an image.
Unsupported pixel format of the source image. Unsupported pixel format of the original image. Source and original images must have the same size. The source image does not contain any blobs.
public Apply ( Bitmap image ) : Bitmap
image System.Drawing.Bitmap Source image to get biggest blob from.
return System.Drawing.Bitmap

Apply() public method

Apply filter to an image.
Unsupported pixel format of the source image. Unsupported pixel format of the original image. Source and original images must have the same size. The source image does not contain any blobs.
public Apply ( BitmapData imageData ) : Bitmap
imageData System.Drawing.Imaging.BitmapData Source image to get biggest blob from.
return System.Drawing.Bitmap

Apply() public method

Apply filter to an image (not implemented).
The method is not implemented.
public Apply ( UnmanagedImage image ) : UnmanagedImage
image UnmanagedImage Image in unmanaged memory.
return UnmanagedImage

Apply() public method

Apply filter to an image (not implemented).
The method is not implemented.
public Apply ( UnmanagedImage sourceImage, UnmanagedImage destinationImage ) : void
sourceImage UnmanagedImage Source image to be processed.
destinationImage UnmanagedImage Destination image to store filter's result.
return void