from moviepy.editor import *
from moviepy.video.fx.resize import resize
import pygame
pygame.display.set_caption('Kumawat!')
clip = VideoFileClip('./dist/视频测试集/l2.5.mp4')
w = 432
h = 768
display = (w, h)
clip.resize(display).preview()
while 1:
for event in pygame.event.get():
if event.type == QUIT:
pygame.quit()
return
参考文章:python - 如何在Tkinter窗口中显示视频预览 - IT工具网 (coder.work)



