What’s wrong with this – why won’t it draw the circle in the window I create?
threeDWinName = "3D View"
cv2.namedWindow(threeDWinName, cv2.CV_WINDOW_AUTOSIZE)
img2 = cv2.imread('white.png', 0)
cv2.imshow(threeDWinName,img2)
cv2.circle(img2, (100,100),100,255,-1)
cv2.imshow(threeDWinName,img2)
Your code works for me. I see the file you are reading is called
white.png, and by loading it with the0you are loading it ingrayscale, so the circle you are drawing is also white. That could be the problem 😉or if you use
img2 = cv2.imread('black.png'), then you get this: