13,344,016 members (84,460 online)
Rate this:
See more:
Most quantizer algorithms reduce the number of colors in an image, but the colors appear as dots throughout the image. When quantizing images which we know have a fixed number of colors, say, logos, it is desirable that similarly colored pixels are clustered together. Is there a quantizing algorithm that is suitable for this purpose?
Posted 23-Mar-10 3:14am
Shree1.6K

Rate this:

## Solution 1

many quantization functions will allow you to control the amount of dithering that occurs once the output palette has been determined. dithering is what gives you the 'dots' - it's an attempt to blend two colors in order to better represent to original image.

if you can turn off dithering, you'll get nice clean edges between areas of solid color.
Rate this:

## Solution 2

Threshold is the obvious dithering technique (or "quantization algorithm") that makes similar sections appear as a solid. If you want to perform a statistical analysis to decided which colors to use beforehand, you could then adjust each pixel according to which of those chosen colors it is closest to. This would give a cartoon look (i.e., looks like cell shading rather than interspersed dots), which I believe is what you are after. Not sure if there is a name for the algorithm which combines closest match and statistical analysis, but if not then just create it and give it any name you like (e.g., Smart Threshold). :)
Hiren Solanki 1-Sep-10 1:51am

intresting

Top Experts
Last 24hrsThis month
 OriginalGriff 338 Pete O'Hanlon 110 CPallini 105 ppolymorphe 98 David_Wimbley 85
 OriginalGriff 2,923 Maciej Los 1,100 Karthik Bangalore 1,027 Jochen Arndt 865 CPallini 767