Created
June 10, 2021 21:08
-
-
Save ZakyHermawan/bec65929114802e40f73844fb920facd to your computer and use it in GitHub Desktop.
take screenshot of chess board using pyautogui
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def take_screenshot(): | |
img = pyautogui.screenshot() | |
board_image = np.array(img) | |
board_image = board_image[:, :, ::-1].copy() | |
return board_image |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment