【python 批量将PPT中各种东西保存为图片 没有水印】

# 安装

pip install Aspose.Slides==24.12.0

# 代码(没有水印,亲测可用!!)

使用导出md为中介,巧妙!但是不能导出整张无水印的幻灯片!

python 复制代码
import aspose.slides as slides

ppt_path = r"xxx.pptx"
out_dir = "save"


with slides.Presentation(ppt_path) as pres:
    # Create Markdown creation options
    md_options = slides.export.MarkdownSaveOptions()
    # Set parameter for render all items (items that are grouped will be rendered together).
    md_options.export_type = slides.export.MarkdownExportType.VISUAL
    # Set folder name for saving images
    md_options.images_save_folder_name = "md-images"
    # Set path for folder images
    md_options.base_path = out_dir

    # Save presentation in Markdown format
    pres.save(out_dir + "/pres.md", slides.export.SaveFormat.MD, md_options)

图片都保存在 save/md-images文件夹中

相关推荐
黄忠2 小时前
大模型之LangGraph技术体系
python·llm
hboot15 小时前
AI工程师第二课 - 数据处理
人工智能·python·数据分析
用户83562907805119 小时前
使用 Python 自动化 PowerPoint 形状布局与格式设置
后端·python
用户83562907805121 小时前
用 Python 自动化 PowerPoint 演讲者备注添加
后端·python
黄忠1 天前
01-系统架构设计-LangGraph状态机与多源异构RAG
python
zzzzzz3101 天前
假如我是掘金管理员,我先给评论区装个'代码审查'系统
python·程序员·机器人
砍材农夫1 天前
python环境|conda安装和使用(2)
后端·python
程序员龙叔2 天前
编写高质量 Skill 系列 -- 如何设计需求分析与用例生成的 SKILL
自动化测试·软件测试·python·软件测试工程师·接口测试·性能测试·skill·ai测试
用户8356290780512 天前
使用 Python 操作 Word 内容控件
后端·python
SpaceAIGlobal2 天前
AI 生成 PPT 工具深度评测与选型指南
人工智能·powerpoint