摘要 |
A method and apparatus for color quantization of an image employs a dynamic color map. Pixels of a first image are mapped into corresponding color space regions while incrementing counts in records of those color space regions. Associated colors of color space regions having largest non-zero counts are included in a color map. If the number of such associated colors is less than a maximum number of color indexes of the color map, the unassigned color indexes are reserved for later assignment. Pixels of subsequent images are also mapped into corresponding color space regions while incrementing counts in records of those color space regions. If unassigned color indexes are available in the color map, associated colors of these color space regions are added to the color map until all color indexes have been assigned.
|