How does np.zeros() create a black background?
I am creating a very simple line drawing program. The problem is that i am still in the learning stage and I jsut stumbled across a problem.
import numpy as np import cv2
img = np.zeros((512,512,3), np.uint8)
img = cv2.line(img,(0,0),(511,511),(255,0,0),5)
how does np.zeros((512,512,3), np.uint8) create a black back ground? What if i want to create a red or a green background? And also, what does these 2 parameters mean?
I hope this answers my problem! Thanks!! :)