initial commit
This commit is contained in:
@@ -0,0 +1,28 @@
|
||||
import pyautogui
|
||||
import mss
|
||||
import cv2
|
||||
import numpy as np
|
||||
|
||||
# while True:
|
||||
# print(pyautogui.position())
|
||||
|
||||
|
||||
|
||||
|
||||
monitor_area = {"top": 120, "left": 330, "width": 1900, "height": 1263}
|
||||
|
||||
sct = mss.mss()
|
||||
|
||||
while True:
|
||||
# Screenshot aufnehmen
|
||||
img = np.array(sct.grab(monitor_area))
|
||||
img_bgr = cv2.cvtColor(img, cv2.COLOR_BGRA2BGR)
|
||||
|
||||
# Anzeige
|
||||
cv2.imshow("Monitor-Ausschnitt", img_bgr)
|
||||
|
||||
# Mit 'q' beenden
|
||||
if cv2.waitKey(1) & 0xFF == ord('q'):
|
||||
break
|
||||
|
||||
cv2.destroyAllWindows()
|
||||
Reference in New Issue
Block a user