Prevent grabcut, houghcircles and houghlines python2 demos from running automatically while browsing demos in the demo list viewer

This commit is contained in:
Adam Geitgey 2015-08-04 14:01:51 -07:00
parent da0c159557
commit e976c448b7
3 changed files with 118 additions and 113 deletions

View File

@ -95,6 +95,8 @@ def onmouse(event,x,y,flags,param):
cv2.circle(img,(x,y),thickness,value['color'],-1)
cv2.circle(mask,(x,y),thickness,value['val'],-1)
if __name__ == '__main__':
# print documentation
print __doc__

View File

@ -10,6 +10,7 @@ import cv2
import numpy as np
import sys
if __name__ == '__main__':
print __doc__
try:

View File

@ -9,6 +9,8 @@ import numpy as np
import sys
import math
if __name__ == '__main__':
try:
fn = sys.argv[1]
except: