代码拉取完成,页面将自动刷新
import os
import sys
dllpath = os.path.join('./libSDL/')
print(dllpath)
os.environ["PYSDL2_DLL_PATH"] = dllpath
import sdl2,sdl2.ext
print(sdl2.SDL_GetRevision())
def run():
sdl2.ext.init()
winflag = (sdl2.SDL_WINDOW_ALLOW_HIGHDPI)
window = sdl2.ext.Window("The Pong Game", size=(800, 600) ,flags=winflag)
window.show()
renderer = sdl2.ext.Renderer(window)
video_file = "./src/2233.mp4"
renderer.
video_texture = renderer.create_texture_from_file(video_file)
running = True
while running:
events = sdl2.ext.get_events()
##print(events)
for event in events:
if event.type == sdl2.SDL_QUIT:
running = False
break
window.refresh()
return 0
if __name__ == "__main__":
sys.exit(run())
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。