Is there a function that tell us what the color of a specific pixel is on a screen?
For example, if I want to know the color of the pixel located at x=100, y=100?
I will appreciate your help.
Thanks!
LG
I think glReadPixels can pick up a single pixel. I’ve only used it for a whole screen but you could try something like the following:
GLubyte color[3];
glReadPixels(x,y,1,1,GL_RGB,GL_UNSIGNED_BYTE,color);
The GL_RGB option tells it to get all 3 color settings. You can change this to get individual colors if you wish.
Tina