def render(self, dst):
t = self.t
self.t += 1.0/30.0
l = 120
black = [245,245,245]
white = [10,10,10]
colors = [black,white]
nsq = 0
x = 0
for xs in range(0,16):
y = 0
for ys in range(0,9):
fg = colors[nsq%2]
bg = colors[(nsq+1) % 2]
dst[y:y+l,x:x+l] = bg
cv2.putText(dst, "%s" % nsq, (x+l/4, y+2*l/3), cv2.FONT_HERSHEY_PLAIN, 3, [0,0,255], thickness = 2, lineType=cv2.LINE_AA)
y+=l
nsq+=1
x+=l
评论列表
文章目录