added color switch and reset trigger

This commit is contained in:
2022-10-14 16:27:32 +02:00
parent c89f1aa3c6
commit 5cf2e9f72a

View File

@@ -230,8 +230,8 @@ class Field:
def get_current_board_state(self):
try:
# get an updated image of the game
#screenshot = self.capture_window.get_screenshot()
screenshot = cv.imread("playfield.jpg")
screenshot = self.capture_window.get_screenshot()
#screenshot = cv.imread("playfield.jpg")
screenshot = screenshot[58:1134, 230:2113] # 1883,1076
self.screenshot = screenshot
# gray = cv.cvtColor(screenshot, cv.COLOR_BGR2GRAY)