Introduction

What is color quantization???

Color quantization can be viewed as a subset of the field of vector quantization. Stated simply vector quantization is the problem of selecting K vectors in some N dimensional space to represent N vectors from that space where K<<N and the total error incurred by the quantization is minimized. Color quantization is then vector quantization in a 3-Dimensional space(RGB, CIE, HLS, ...). The process of color image quantization is often broken into four phases, Heckbert[2].
  1. Sampling the original image for color statistics.

  2. Choosing a color map based on those statistics.

  3. Mapping the colors to their representative in the color map.

  4. Quantizing and drawing the new image.
Phase 4 is a trivial matter regardless of the quantization method. The other three phases however are more strongly connected. In particular the method used for phases 1 and 2 will determine the best method for accomplishing phase 3.

In general algorithms for color quantization can be broken into two categories: Uniform and Non-Uniform.

The remainder of this presentation will focus on 4 different algorithms: Uniform, Popularity, Median Cut & Octree. Throughout the discussions the color space is assumed to be RGB and K = 256 although none of the algorithms are dependent on these assumptions.