cv2
2020-08-14 本文已影响0人
yuerxiaoshui
特别注意,这个 videowriter 的 size(width, height) 与图像 shape(height, width, channel) 顺序不一样, 调了一个多小时才发现
size = (img_shape[1], img_shape[0])
video_writer = cv2.VideoWriter(video_path, fourcc, fps, size)
特别注意,这个 videowriter 的 size(width, height) 与图像 shape(height, width, channel) 顺序不一样, 调了一个多小时才发现
size = (img_shape[1], img_shape[0])
video_writer = cv2.VideoWriter(video_path, fourcc, fps, size)