Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我尝试通过 cv2 中的图像创建视频,我成功创建了 mp4 视频:
fourcc = cv2.VideoWriter_fourcc(*'mp4v') out = cv2.VideoWriter('video.mp4', fourcc, FRAME_RATE, (img.shape[1], img.shape[0]))
如何创建 ogg 和 webm 视频文件?这些格式的fourcc编解码器是什么?
ogg 具有编解码器“theo”:
fourcc = cv2.VideoWriter_fourcc(*'theo')
您还应该能够执行以下格式:
fourcc = cv2.VideoWriter_fourcc('T', 'H', 'E', 'O')