mirror of
https://github.com/YaoFANGUK/video-subtitle-remover.git
synced 2026-06-10 10:58:12 +08:00
init
This commit is contained in:
12
backend/inpaint/utils/get_point_coor.py
Normal file
12
backend/inpaint/utils/get_point_coor.py
Normal file
@@ -0,0 +1,12 @@
|
||||
import cv2
|
||||
|
||||
def click_event(event, x, y, flags, param):
|
||||
if event == cv2.EVENT_LBUTTONDOWN:
|
||||
print("Point coordinates ({}, {})".format(x, y))
|
||||
img = cv2.imread("./example/remove-anything/dog.jpg")
|
||||
|
||||
cv2.imshow("Image", img)
|
||||
cv2.setMouseCallback("Image", click_event)
|
||||
cv2.waitKey(0)
|
||||
|
||||
cv2.destroyAllWindows()
|
||||
Reference in New Issue
Block a user