The GMImage quantize methods allow for quantisation to occur in RGB colorspace (default), grescale, and others more suitable for photos , such as YUV
The documentation shows that greyscale method has a constant value of 2
There is mention of constants for the other colorspaces, and I cannot find any listed online from Monkeybread or GraphisMagick.
Does anyone have these constants values?
you find constants here:
and here is a list:
UndefinedColorspace = 0,
RGBColorspace = 1 (Plain old RGB colorspace),
GRAYColorspace = 2 (Plain old full-range grayscale),
TransparentColorspace = 3 (RGB but preserve matte channel during quantize),
OHTAColorspace = 4,
XYZColorspace = 5 (CIE XYZ),
YCCColorspace = 6 (Kodak PhotoCD PhotoYCC),
YIQColorspace = 7,
YPbPrColorspace = 8,
YUVColorspace = 9,
CMYKColorspace = 10 (Cyan, magenta, yellow, black, alpha),
sRGBColorspace = 11 (Kodak PhotoCD sRGB),
HSLColorspace = 12 (Hue, saturation, luminosity),
HWBColorspace = 13 (Hue, whiteness, blackness),
LABColorspace = 14 (LAB colorspace not supported yet other than via lcms),
CineonLogRGBColorspace = 15 (RGB data with Cineon Log scaling, 2.048 density range),
Rec601LumaColorspace = 16 (Luma (Y) according to ITU-R 601),
Rec601YCbCrColorspace = 17 (YCbCr according to ITU-R 601),
Rec709LumaColorspace = 18 (Luma (Y) according to ITU-R 709),
Rec709YCbCrColorspace = 19 (YCbCr according to ITU-R 709)
We had a time, where I preferred to put constants in examples and not fill the plugin with them.
But then later I did put in the constants to the class.
Experimentation now begins.