Description: opencv
def random_color(random):
Return a random color
icolor = random.randint(0, 0xFFFFFF)
return cv.Scalar(icolor & 0xff, (icolor >> 8) & 0xff, (icolor >> 16) & 0xff)
if __name__ == __main__ :
# some constants
width = 1000
height = 700
window_name = Drawing Demo
number = 100
delay = 5
line_type = cv.CV_AA # change it to 8 to see non-antialiased graphics
# create the source image
image = cv.CreateImage( (width, height), 8, 3)
# create window and display the original picture in it
cv.NamedWindow(window_name, 1)
cv.SetZero(image)
cv.ShowImage(window_name, image)
# create the random number
random = Random().....To Be continued
To Search:
File list (Check if you may need any files):
drawing.py