Re: [gtk-list] Re: how to convert windows RGB color to GdkColor




   old color       new color
   dec  hex        dec hex
	0   00          0   0000
	1   01         257  0101
	2   02         514  0202
   ...
   63   3f        16191  3f3f
   ...
   254  fe        65278  fefe
   255  ff        65535  ffff

Another subscriber sent me prive e-mail that made sense to me -- to
map 00..ff into 0000..ffff as uniformly as possible, you multiply by
257 rather than 256 (this is also effectively what Rick was saying).
That's equivalent to the shift-and-add being discussed.  Sorry, all.
-- 
Joseph J. Pfeiffer, Jr., Ph.D.       Phone -- (505) 646-1605
Department of Computer Science       FAX   -- (505) 646-1002
New Mexico State University          http://www.cs.nmsu.edu/~pfeiffer



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