Hi!
I make some program to recognize pixel i few position. I try pyguiauto & PIL.
Programing with pyautogui was problematic when after 3/4min slowdown process and hole System
(after this PyCharm report me to stop process of program). I guess pyautogui don't have clearing cash or temp(hmm everytime after matching colors?).
I use this
Afterall i try use PIL and ImageGrab. But from start i feel little laggy like screen freez. I dont have this time unstablle working. After even 1h still work.no leaking memory.
My question is:
-Where I make mistake, I doing something wrong with pyautogui?
-I only try my code without compile in PyCharm, it will incrase efficity when i compile to exe?
-do you have guys any idea how to make? got something else better then this?
-maybe betther option is to capture hole screen at onece and take 13 pixels ? (i dont know how to do that)
my last working part of code:
they mixing in one time in one loop/tick in hole code
I make some program to recognize pixel i few position. I try pyguiauto & PIL.
Programing with pyautogui was problematic when after 3/4min slowdown process and hole System

I use this
pyautogui.pixelMatchesColor(x, y, (R, G, B), tolerance=10)In code every 500/200ms it take 13 diffrend positions.
Afterall i try use PIL and ImageGrab. But from start i feel little laggy like screen freez. I dont have this time unstablle working. After even 1h still work.no leaking memory.

My question is:
-Where I make mistake, I doing something wrong with pyautogui?
-I only try my code without compile in PyCharm, it will incrase efficity when i compile to exe?
-do you have guys any idea how to make? got something else better then this?
-maybe betther option is to capture hole screen at onece and take 13 pixels ? (i dont know how to do that)
my last working part of code:
def takeitt(self): global r, g, b pixelColor = ImageGrab.grab(bbox=(x, y, x + 2, y + 2)).getpixel((1, 1)) r = pixelColor[0] g = pixelColor[1] b = pixelColor[2] def hp80_check(self): global x, y, hp80 i = 3 x = arr[i, 2] y = arr[i, 3] self.takeitt() if r == arr[i, 4] and g == arr[i, 5] and b == arr[i, 6]: hp80 = 1 else: hp80 = 0hp80 is a 1 matchpixel from 13 differnd def.
they mixing in one time in one loop/tick in hole code