asweigart / pyscreeze

PyScreeze is a simple, cross-platform screenshot module for Python 2 and 3.
BSD 3-Clause "New" or "Revised" License
194 stars 96 forks source link

Add ability to pass a pre-loaded image to openCV locate functions. #74

Closed Triscuit2311 closed 2 years ago

Triscuit2311 commented 3 years ago

This allows users to load an image once and use it multiple times. Also negates having to store images on disk after they are loaded.

this is now legal:

needle = pyscreeze._load_cv2("needle.png")
result = pyautogui.locateOnScreen(needle)