Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
如何使用 Python Arcade 库截取当前窗口的屏幕截图?
我已经使用 Python Arcade 库构建了一个模拟器,并希望在发生有趣事件时以编程方式截取窗口的屏幕截图。这可能吗?
arcade.draw_commands.get_image(x=0, y=0, width=None, height=None)
从屏幕上获取图像。您可以像这样保存图像:
image = get_image() image.save('screenshot.png', 'PNG')
资源