使用python播放视频文件
基于python和opencv实现的
import numpy as np
import cv2
cap = cv2.VideoCapture('f:/rain_of_lovesickness.mp4')
while (cap.isOpened()):
ret, frame = cap.read()
cv2.imshow('frame', frame)
if cv2.waiTKEy(40) & 0xFF == ord('q'):
break
cap.release()
cv2.destroyAllwindows()
相关文章