quantize quantize

Color quantization. Specifies color-quantization attributes for GIF output conversion.

quantize= *type*[, *dither*[, *numColors*[, *colorList*]]]



Specifies the palette type.

Set to adaptive to calculate an optimal palette for the image.

Set to web or mac to choose a pre-defined palette.

Note: The mac pallet type is only supported for GIF and PNG8 formats but not for GIF-Alpha and PNG8-Alpha formats.



Specifies the dithering options.

Set to diffuse for Floyd-Steinberg error diffusion

Set to off to disable dithering.


Number of output colors (2-256)

Specifies how many colors are included in the adaptive palette.


A comma-separated list of forced RGB colors in hex6 format

Lets you specify the colors to include in an adaptive palette. If the number of colors specified is less than numColors , additional colors are calculated based on the image content.

Properties section-8ab5035055b24b858270d260912a7f3d

Request attribute. It applies regardless of the current layer setting. Used only if fmt=gif, fmt=gif-alpha, fmt=png8, or fmt=png8-alpha. Ignored otherwise.

The colors specified with colorList must consist of RGB values in hex6 format (see color without 0x prefix. No other color specifiers are permitted. The modifier numColors must be 2–256.

Default section-ca3e817617244e8798ccff67b2023a32


Example section-e34aca7587d548a7ae9d4266b80c9451

Generate a GIF thumbnail using the web palette and no dithering:

http:// *Server*/myRootId/myImageId?req=tmb&fmt=gif&quantize=web,off

Convert the image to a bi-tonal GIF with key-color transparency and force colors to black and white:

http:// *Server*/myRootId/myImageId?fmt=gif-alpha&wid=100&quantize=adaptive,off,2,000000,ffffff

See also section-ea5e8de6084540cf86010370a4d0f01f

fmt= , color