412 Subj : Re: How to read a pixel from a DIB? To : borland.public.cpp.borlandcpp From : Sebastian Ledesma Date : Wed Oct 20 2004 01:03 pm " Bruce Salzman" escribió en el mensaje news:41767a08$1@newsgroups.borland.com... > > "Sebastian Ledesma" wrote in message > news:41766038@newsgroups.borland.com... > > Hi: > > > > Context: BC502+Win32+OWL > > > > There is a easy/official way to read a pixel from a TDib object? I > > want to > > know the RGB of that pixel > > in order to adjust the color of a control above that Dib. > > > > Select it into a TDC and use GetPixel()? > > Regards, > Bruce > Bruce: That's the way I will use, only lazzines before coding. I have to convert X,Y coordinates into a linear coordinate (hey that's so hard!!! :-) ), also what about for non 24 bits bitmaps. In 16 bits bitmaps I will have RGB in 5 bits, in 8 bits I will have a palette index, and in 4 bits (old 16 colored bitmaps) something similar. Saludos Sebastian . 0