boofcv.alg.color
Class ColorLab
- java.lang.Object
-
- boofcv.alg.color.ColorLab
-
public class ColorLab extends java.lang.ObjectConversion between RGB and CIE LAB color space. LAB color is designed to approximate human vision. L for lightness and a and b for the color-opponent dimensions, The reference white used in the conversions below is D65.
-
-
Field Summary
Fields Modifier and Type Field and Description static doubleepsilonstatic floatepsilon_fstatic doublekappastatic floatkappa_fstatic doubleXrstatic floatXr_fstatic doubleYrstatic floatYr_fstatic doubleZrstatic floatZr_f
-
Constructor Summary
Constructors Constructor and Description ColorLab()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method and Description static voidrgbToLab_F32(Planar<GrayF32> rgb, Planar<GrayF32> lab)Convert a 3-channelPlanarimage from RGB into LAB.static voidrgbToLab_U8(Planar<GrayU8> rgb, Planar<GrayF32> lab)Convert a 3-channelPlanarimage from RGB into LAB.static voidsrgbToLab(double r, double g, double b, double[] lab)Conversion from normalized RGB into LAB.static voidsrgbToLab(float r, float g, float b, float[] lab)Conversion from normalized RGB into LAB.
-
-
-
Field Detail
-
epsilon
public static final double epsilon
- See Also:
- Constant Field Values
-
kappa
public static final double kappa
- See Also:
- Constant Field Values
-
Xr
public static final double Xr
- See Also:
- Constant Field Values
-
Yr
public static final double Yr
- See Also:
- Constant Field Values
-
Zr
public static final double Zr
- See Also:
- Constant Field Values
-
epsilon_f
public static final float epsilon_f
- See Also:
- Constant Field Values
-
kappa_f
public static final float kappa_f
- See Also:
- Constant Field Values
-
Xr_f
public static final float Xr_f
- See Also:
- Constant Field Values
-
Yr_f
public static final float Yr_f
- See Also:
- Constant Field Values
-
Zr_f
public static final float Zr_f
- See Also:
- Constant Field Values
-
-
Method Detail
-
srgbToLab
public static void srgbToLab(double r, double g, double b, double[] lab)Conversion from normalized RGB into LAB. Normalized RGB values have a range of 0:1
-
srgbToLab
public static void srgbToLab(float r, float g, float b, float[] lab)Conversion from normalized RGB into LAB. Normalized RGB values have a range of 0:1
-
rgbToLab_U8
public static void rgbToLab_U8(Planar<GrayU8> rgb, Planar<GrayF32> lab)
Convert a 3-channelPlanarimage from RGB into LAB. RGB is assumed to have a range from 0:255 NOTE: Input and output image can be the same instance.- Parameters:
rgb- (Input) RGB encoded imagelab- (Output) LAB encoded image
-
rgbToLab_F32
public static void rgbToLab_F32(Planar<GrayF32> rgb, Planar<GrayF32> lab)
Convert a 3-channelPlanarimage from RGB into LAB. RGB is assumed to have a range from 0:255 NOTE: Input and output image can be the same instance.- Parameters:
rgb- (Input) RGB encoded imagelab- (Output) LAB encoded image
-
-
DataMelt 3.0 © DataMelt by jWork.ORG