Like you this program? well, now i wish to tell you something interesting and funny too!
- despite this program and the IDE card that i have done, amiga.org refused to join me on his Forum...maybe my bad english language...anyway, after more then a year, i am still waiting a reply from him!
- inside this program there is two funny algorythms; one of sorting, to choose the best color from a palette and the other...ta-da...a full 32 bit division, with MC68000 instructions. All of this without, guess you, any knowledge of 'science in algorythm' and without any help from books like 'Algorythm XYZ' by Addison-Wesley...
The algorythm of sorting works in this way: for the three components of the color the program is looking for (Red, Green and Blue), three tables are done, one for every component, with a graduatory, from the entry (in the color palette) more similar to the less similar. Done this tables, a fourthy is done with the last graduatory, obtained adding the positions, for every entry, in the three tables. The new graduatory reports as first, the entry with the lesser value (near zero), that is the entry more similar to the requested color.
That's all!