Color filtering.

Namespace:  AForge.Imaging.Filters
Assembly:  AForge.Imaging (in AForge.Imaging.dll) Version: 2.2.5.0 (2.2.5.0)

Syntax

C#
public class ColorFiltering : BaseInPlacePartialFilter

Remarks

The filter filters pixels inside/outside of specified RGB color range - it keeps pixels with colors inside/outside of specified range and fills the rest with specified color.

The filter accepts 24 and 32 bpp color images for processing.

Sample usage:

CopyC#
// create filter
ColorFiltering filter = new ColorFiltering( );
// set color ranges to keep
filter.Red   = new IntRange( 100, 255 );
filter.Green = new IntRange( 0, 75 );
filter.Blue  = new IntRange( 0, 75 );
// apply the filter
filter.ApplyInPlace( image );

Initial image:

Result image:

Inheritance Hierarchy

System..::.Object
  AForge.Imaging.Filters..::.BaseInPlacePartialFilter
    AForge.Imaging.Filters..::.ColorFiltering

See Also