I would use the following algorithm:

0. Convert a sample image in a BufferedImage - just so you can compare.
1. For each pixel on the screen:
1.1. Create screenshot of a rectangular part of a...