🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.sys.amiga.tech
Article #12407

Re: Color compression routines (4096 to 256) wanted.

#12407
From: Stephen B Coy
Date: Thu, 27 Apr 1989 20:06
31 lines
1978 bytes
In article <11430@well.UUCP>, ewhac@well.UUCP (Leo 'Bols Ewhac' Schwab) writes:
> In article <33747@kilowatt.uucp> raz@kilowatt.uucp (Raz- Berry) writes:
> > I need a basic flowchart
> > on taking a 4096 color palette and converting it down to
> > 256. Initially I was thinking that:
> >
> > [algorithm deleted for brevity]
> 
> 	Suppose I have a simple HAM picture.  The left half of the screen is
> various hues of purple, and the right half of the screen is various hues of
> blue.  Separating these two fields is a vertical line, one pixel wide, that
> is solid white.
> 
> 	Now, if you were to do a histogram on this image, you'd probably
> find the most popular 256 entries were hues of purple and blue, and white
> would be right at the bottom of the list.  However, that white line is a
> prominent feature, because of its contrast with the rest of the image.  So

But rememeber, he's starting with a 4096 color palette which means
only 16 hues of pure blue.  Even allowing for going slightly off
color you'll probably end up with less than 50 shades each of blue
and purple.  This still leaves over 100 palette entries for various
shades of white.  When DBW_render first appeared I coded up the
algrothm as proposed for displaying the images on an Apollo with a
256/16M palette.  The images looked fine.  For mapping the
non-popular colors onto the 256 color palette I used a simple
distance function in RGB space.  Obviously not the best but good
enough.

Stephen Coy
uw-beaver!ssc-vax!coy
Technical Details
Message-ID: <2625@ssc-vax.UUCP>
Path: arc1-ca.pugleaf.net!utzoo!attcan!utgpu!jarvis.csri.toronto.edu!mailrus!cornell!uw-beaver!fluke!ssc-vax!coy
References: <33747@kilowatt.uucp> <11430@well.UUCP>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!attcan!utgpu!jarvis.csri.toronto.edu!mailrus!cornell!uw-beaver!fluke!ssc-vax!coy
From: coy@ssc-vax.UUCP (Stephen B Coy)
Newsgroups: comp.sys.amiga.tech
Subject: Re: Color compression routines (4096 to 256) wanted.
Keywords: HAM, 256 color, Amiga, Sun
Message-ID: <2625@ssc-vax.UUCP>
Date: 27 Apr 89 20:06:13 GMT
References: <33747@kilowatt.uucp> <11430@well.UUCP>
Organization: Boeing Aerospace Corp., Seattle WA
Lines: 31