Class GreyscaleLightnessConverter
- java.lang.Object
-
- science.aist.imaging.core.imageprocessing.conversion.greyscale.GreyscaleLightnessConverter
-
- All Implemented Interfaces:
ColorToGreyScaleConverter
public class GreyscaleLightnessConverter extends Object implements ColorToGreyScaleConverter
Converts a RGB Color into a greyscale color using lightness method
- Since:
- 1.0
- Author:
- Andreas Pointner
-
-
Constructor Summary
Constructors Constructor Description GreyscaleLightnessConverter()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description doubletoGreyscale(double r, double g, double b)Converts a color pixel into a greyscale pixel
-
-
-
Method Detail
-
toGreyscale
public double toGreyscale(double r, double g, double b)Description copied from interface:ColorToGreyScaleConverterConverts a color pixel into a greyscale pixel- Specified by:
toGreyscalein interfaceColorToGreyScaleConverter- Parameters:
r- the red value in range [0,255]g- the green value in range [0, 255]b- the blue value in range [0, 255]- Returns:
- the resulting greyscale value in range [0, 255]
-
-