Home>

you need to compare 2. Images with the same resolution, without some kind of hashing and other complex pieces.

Suppose I have 2. Screenshot 200x200 pixels. If they are fully identical, then ... Something happens (some variable= true). I capture images using:

from Pil Import ImageGrab
SCR= imagegrab.grab

(preferably using the library CV2 (OpenCV) ).

Example of images:

And whether it is possible not to compress images, but what color is the pixel in any coordinates? And compare it with the saved color value in the variable? @ Gil9red.

DIPPEROK2021-05-05 16:26:10

You can, after parsing PillOw or OpenCV, the picture will be an array with pixels (values ​​or tuple with values, type (255, 0, 0))

gil9red2021-05-05 16:26:10

And you can upload and subtract each other to Numpy, and then calculate the average deviation

eri2021-05-05 16:26:10