how do I determine what the color of a given pixel is?
Posted: Mon May 02, 2011 9:40 pm
How do I detect the color of what has been drawn to the screen?
For example, I've used "set the pencolor to black", "choose pencil" and "click at x,y" to do some code based painting but now I want the code to be able to know what the color of any given pixel on screen is.
Do I have to import a snapshot and then use some function to read the color of pixels in an image? How would I detect the color of pixels in an image?
I have a similar thread in the other forum on here but this one is more to the point and probably in the right place.
For example, I've used "set the pencolor to black", "choose pencil" and "click at x,y" to do some code based painting but now I want the code to be able to know what the color of any given pixel on screen is.
Do I have to import a snapshot and then use some function to read the color of pixels in an image? How would I detect the color of pixels in an image?
I have a similar thread in the other forum on here but this one is more to the point and probably in the right place.