python 腾讯会议录屏文件转化为MP4
创始人
2024-09-26 15:24:30
0
import os  import ffmpeg from ffmpeg import output, run   def convert_wemtv_to_mp4(input_file, output_dir):     """     将 WEMTV 文件转换为 MP4 文件并保存      Args:     input_file (str): 输入 WEMTV 文件路径     output_dir (str): 输出 MP4 文件保存目录     """     try:         if  os.path.exists(input_file):             print(f"input_file:存在")         # 检查输出目录是否存在         if not os.path.exists(output_dir):             os.makedirs(output_dir)             print(f"output_dir:不存在")          # 构建输出文件路径         output_file = os.path.join(output_dir, output_dir + ".mp4")          print(f"input_file:{input_file}")          # 创建 FFmpeg 处理流         stream = input(input_file)         print(f"stream:{stream}")         stream = output(stream, output_file, codec='libx264', f='mp4')          # 执行转换         run(stream)         print(f"转换成功: {output_file}")     except Exception as e:         print(f"转换失败: {input_file}")         print(e)   # 示例用法 input_file = 'path/to/input.wemtv' output_file = 'path/to/output.mp4' output_dir = 'directory' convert_wemtv_to_mp4(input_file, output_dir) 

相关内容

热门资讯

分享认知!微乐小程序辅助工具!... 分享认知!微乐小程序辅助工具!微乐自建房脚本使用安全吗(真是有辅助教程)1)有没有挂:进一步探索有辅...
分享个大家!微乐小程序辅助工具... 分享个大家!微乐小程序辅助工具!微乐陕西麻将破解(果然真的是有辅助脚本)1)辅助插件:进一步探索辅助...
分享一款!微乐小程序自建房辅助... 分享一款!微乐小程序自建房辅助!微乐富足和靠谱吗(果然真的是有辅助技巧)暗藏猫腻,小编详细说明破解器...
实测揭晓!微乐小程序自建房辅助... 实测揭晓!微乐小程序自建房辅助!微信小程序微乐辅助器ios(本来有辅助app)透视方法中分为三种模型...
科普攻略!微乐小程序辅助工具!... 科普攻略!微乐小程序辅助工具!微信微乐辅助器使用教程(总是真的是有辅助插件)亲,关键说明,透视脚本安...
免费测试版!微乐小程序自建房辅... 免费测试版!微乐小程序自建房辅助!微乐麻将自建房app(都是真的是有辅助软件)1、很好的工具软件,可...
每日必看教程!微乐小程序自建房... 每日必看教程!微乐小程序自建房辅助!微乐春天小程序辅助(一直真的有辅助器)1、很好的工具软件,可以解...
科技通报!微乐小程序自建房辅助... 科技通报!微乐小程序自建房辅助!微乐家乡app辅助器(其实有辅助插件)1、打开软件启动之后找到中间准...
必备教程!微乐小程序自建房辅助... 必备教程!微乐小程序自建房辅助!微信小程序四川微乐脚本(总是有辅助工具)1、金币登录送、破产送、升级...
信息共享!微乐小程序辅助工具!... 信息共享!微乐小程序辅助工具!微信小程序游戏辅助器(果然是有辅助脚本)1、下载好透视辅助下载之后点击...