C# Класс AForge.Imaging.Filters.ExtractNormalizedRGBChannel

Extract normalized RGB channel from color image.

Extracts specified normalized RGB channel of color image and returns it as grayscale image.

Normalized RGB color space is defined as: r = R / (R + G + B ), g = G / (R + G + B ), b = B / (R + G + B ), where R, G and B are components of RGB color space and r, g and b are components of normalized RGB color space.

The filter accepts 24, 32, 48 and 64 bpp color images and produces 8 (if source is 24 or 32 bpp image) or 16 (if source is 48 or 64 bpp image) bpp grayscale image.

Sample usage:

// create filter ExtractNormalizedRGBChannel filter = new ExtractNormalizedRGBChannel( RGB.G ); // apply the filter Bitmap channelImage = filter.Apply( image );
Наследование: BaseFilter
Показать файл Открыть проект

Открытые методы

Метод Описание
ExtractNormalizedRGBChannel ( ) : System

Initializes a new instance of the ExtractNormalizedRGBChannel class.

ExtractNormalizedRGBChannel ( short channel ) : System

Initializes a new instance of the ExtractNormalizedRGBChannel class.

Защищенные методы

Метод Описание
ProcessFilter ( UnmanagedImage sourceData, UnmanagedImage destinationData ) : void

Process the filter on the specified image.

Описание методов

ExtractNormalizedRGBChannel() публичный метод

Initializes a new instance of the ExtractNormalizedRGBChannel class.
public ExtractNormalizedRGBChannel ( ) : System
Результат System

ExtractNormalizedRGBChannel() публичный метод

Initializes a new instance of the ExtractNormalizedRGBChannel class.
public ExtractNormalizedRGBChannel ( short channel ) : System
channel short Normalized RGB channel to extract.
Результат System

ProcessFilter() защищенный метод

Process the filter on the specified image.
protected ProcessFilter ( UnmanagedImage sourceData, UnmanagedImage destinationData ) : void
sourceData UnmanagedImage Source image data.
destinationData UnmanagedImage Destination image data.
Результат void