首页 > 编程知识 正文

如何在python中显示电脑中的片,python读取片并显示

时间:2023-05-05 10:46:05 阅读:238199 作者:720

python使用系统打开文件、显示图片 import platformuserPlatform=platform.system()# 获取操作系统fileDir='./Desktop/aaa.png'if userPlatform == 'Darwin':# Mac subprocess.call(['open', fileDir])elif userPlatform == 'Linux':# Linux subprocess.call(['xdg-open', fileDir])else:# Windows os.startfile(fileDir) Good Luck~~~

版权声明:该文观点仅代表作者本人。处理文章:请发送邮件至 三1五14八八95#扣扣.com 举报,一经查实,本站将立刻删除。