Newsgroups: comp.sys.atari.st Path: utzoo!utgpu!watserv1!watmath!lsuc!jimomura From: jimomura@lsuc.on.ca (Jim Omura) Subject: Re: GemView (new version and some questions) Organization: Consultant, Toronto Date: Thu, 23 May 1991 09:06:38 GMT Message-ID: <1991May23.090638.25503@lsuc.on.ca> References: <3272@laura.UUCP> <1991May22.193554.26435@lsuc.on.ca> In article <1991May22.193554.26435@lsuc.on.ca> jimomura@lsuc.on.ca (Jim Omura) writes: >In article <3272@laura.UUCP> haacke@exunido.UUCP (Ralf Haacke) writes: ... >>- A new color reduce algorithm. I have the followed idea: >> A color is a point in a 3-dim-room (N^3). First calculate the distance >> from each point to each other and save the nearest point with the distance. >> Next searching the nearest neighbours and make this two point to one. The >> new points is nearer to a point which represent more points then the >> other. From the new point calculate the distance to all other points and >> save the nearest (some other points must update, if the new point is nearer >> as the nearest neighbour before). Then begin to search the nearest ...., >> until we have reduce enough. > > I felt that you did a really good job on the colour reduction >algorythm. The colour selection seems better than on a couple of >other programs I've been using ("VDI_GIF" and another one I can't >remember offhand). I've been kicking around ideas for colour >reduction codes for a while now and I haven't gotten around to >writing one yet, but it seemed to me that it might be easier to >work in a 2D framework based on Hue and Intensity, which is the >way a television signal works. But to do this you have to start >by converting the palette from RGB's for most picture format, then >do the calculations, and then re-convert to the target palette >style (Atari in this case). So there I was trying to sleep when it hit me at about 4:30 AM that I was wrong. This *still* isn't a 2D system because you still have to consider "Saturation". There doesn't seem to be any way to reduce it to 2D. At least I don't think so. I still might use Hue/Intensity/Saturation instead of RGB if I get around to writing a conversion. No rush though. I have other things to get to first. > Working from Hue and Intensity, I think you could give preference >to one or the other for your colour assignments, as an option for >the user. That is to say you could allow the user to chose whether >colour assignments are weighted to give the maximum detail in terms >of the hues (which could result in a pastel, low contrast image with >a lot of detail in terms of colours) or maximum detail in terms of >contrast (which might result in a picture with fewer colours, but >more shading). > > Again, I'll emphasize that I haven't gotten around to writing >this code yet so I don't know if it's going to work out the way >I'm expecting it to. -- Jim Omura, 2A King George's Drive, Toronto, (416) 652-3880 lsuc!jimomura Byte Information eXchange: jimomura