Grayscale image using R-Y algorithm.

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

Syntax

C#
public static readonly Grayscale RMY

Remarks

The instance uses R-Y algorithm to convert color image to grayscale. The conversion coefficients are:

  • Red: 0.5;
  • Green: 0.419;
  • Blue: 0.081.

Sample usage:

CopyC#
// apply the filter
Bitmap grayImage = Grayscale.CommonAlgorithms.RMY.Apply( image );

See Also