Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

python to make video

import cv2
import numpy as np
 

frameSize = (500, 500)

out = cv2.VideoWriter('output_video.avi',cv2.VideoWriter_fourcc(*'DIVX'), 60, frameSize)

for i in range(0,255):
    img = np.ones((500, 500, 3), dtype=np.uint8)*i
    out.write(img)

out.release()
Source by pythonexamples.org #
 
PREVIOUS NEXT
Tagged: #python #video
ADD COMMENT
Topic
Name
8+4 =