python opencv VideoWriter: OpenCV: Frame size does not match video size -
i have series of images , want opencv read images , create video first image last. images called 1,2,3,4....151.
import cv2 img=[] in range(0,151): img.append(cv2.imread(str(i)+'.png')) height,width,layers=img[1].shape video=cv2.videowriter('video.avi',-1,1,(width,height)) j in range(0,151): video.write(img[j]) cv2.destroyallwindows() video.release()
and following error raised:
opencv: frame size not match video size
after video created few images used produce video.
where incorrect?
for "mmoviewriter.status: 3. error: cannot save", can try removing video.avi file created during tests.
Comments
Post a Comment