mirror of
https://github.com/opencv/opencv.git
synced 2026-07-29 23:33:05 +04:00
Samples Python:
* Unused variables * Bad identation
This commit is contained in:
@@ -53,8 +53,8 @@ if __name__ == '__main__':
|
||||
small = cv2.pyrDown(small)
|
||||
|
||||
def onmouse(event, x, y, flags, param):
|
||||
h, w = img.shape[:2]
|
||||
h1, w1 = small.shape[:2]
|
||||
h, _w = img.shape[:2]
|
||||
h1, _w1 = small.shape[:2]
|
||||
x, y = 1.0*x*h/h1, 1.0*y*h/h1
|
||||
zoom = cv2.getRectSubPix(img, (800, 600), (x+0.5, y+0.5))
|
||||
cv2.imshow('zoom', zoom)
|
||||
|
||||
Reference in New Issue
Block a user