Re: [Gimp-developer] Floyd-Steinberg/GIF color optimization



Hi Robert

On Tue, Oct 21, 2014 at 10:04:14AM -0500, Robert Hanson wrote:
http://chemapps.stolaf.edu/jmol/test/dither.htm .  The solution was to

This page seems to use JavaScript and WebGL, and so I'm not able to view
it. It would have been better if you had sent a link to static images of
the source and result.

partition red, green, and blue channels into a 6 x 6 x 6 color space,
allowing 216 colors in total. Not perfect, but amazingly good, I think.

So you are doing FS dithering with a fixed uniform palette?

The problem comes when I have a small molecule with not too many colors. If
I go just over 256, then the FS algorithm cuts this down to something like
64 colors. I'm wondering if I could get some advise as to how to optimize a
set of colors down to 255 colors without undershooting in such a dramatic
way while still using FS.

You are looking for color quantization methods. You can find description
of an octree method in Graphics Gems I. GIMP uses median cut.

See https://www.cs.cmu.edu/~ph/ciq_thesis for Heckbert's thesis on
median cut.

                Mukund

Attachment: pgpY4WCl4IIop.pgp
Description: PGP signature



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]