cv2 open blank window

Solutions on MaxInterview for cv2 open blank window by the best coders in the world

showing results for - "cv2 open blank window"
Alma
05 Sep 2019
1# sadly, if you're using cv2.imread(), not many options exist...
2
3import cv2
4import numpy as np
5# black blank image
6blank_image = np.zeros(shape=[512, 512, 3], dtype=np.uint8)
7# print(blank_image.shape)
8cv2.imshow("Black Blank", blank_image)
9# white blank image
10blank_image2 = 255 * np.ones(shape=[512, 512, 3], dtype=np.uint8)
11cv2.imshow("White Blank", blank_image2)
12cv2.waitKey(0)
13cv2.destroyAllWindows()
queries leading to this page
cv2 open blank windowcv2 open blank window