python cv2.videowriter.write
时间: 2023-12-13 09:05:32 浏览: 208
AVI Writer
4星 · 用户满意度95%
The cv2.videowriter.write() function in Python OpenCV is used to write a frame into a video file. It takes the following syntax:
cv2.videowriter.write(frame)
Here, the frame is the image array that needs to be written into the video file. The function returns a boolean value indicating whether the frame was successfully written or not. If the return value is true, the frame was successfully written into the video file, otherwise, it indicates a failure.
Note: Before using the write() function, we need to create a VideoWriter object using the cv2.VideoWriter() function.
阅读全文