Skip to content

Commit 807f5e3

Browse files
committed
Merge pull request opencv#10055 from mabdullahrafique:patch-1
2 parents 11330b9 + c180047 commit 807f5e3

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

samples/python/digits_video.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ def main():
5555
if not (16 <= h <= 64 and w <= 1.2*h):
5656
continue
5757
pad = max(h-w, 0)
58-
x, w = x-pad/2, w+pad
58+
x, w = x - (pad // 2), w + pad
5959
cv2.rectangle(frame, (x, y), (x+w, y+h), (0, 255, 0))
6060

6161
bin_roi = bin[y:,x:][:h,:w]
@@ -98,3 +98,4 @@ def main():
9898

9999
if __name__ == '__main__':
100100
main()
101+
cv2.destroyAllWindows()

0 commit comments

Comments
 (0)