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) 

相关内容

热门资讯

黑科技辅助(WEpoke)we... 黑科技辅助(WEpoke)wepoke有没有挂(透视)外挂透明挂辅助黑科技(原来真的有挂)-哔哩哔哩...
wepoke黑科技!wepok... wepoke黑科技!wepoke辅助使用教程(WePoKe黑科技)一直有挂(有挂详情)-哔哩哔哩1、...
wPK最新黑科技!wpk俱乐部... 1、wPK最新黑科技!wpk俱乐部有ai吗(WPK ai辅助)起初真的是有挂(2025已更新)(哔哩...
黑科技辅助(WePoke)we... 黑科技辅助(WePoke)wepoke透明黑科技(透视)外挂透明挂辅助挂(原来真的有挂)-哔哩哔哩1...
wepoke真的有挂!wepo... wepoke真的有挂!wepoke软件(WePoKe黑科技)确实真的有挂(有挂方法)-哔哩哔哩;we...
黑科技辅助(wepoke)we... 黑科技辅助(wepoke)wepoke透明黑科技(透视)外挂透明挂辅助软件(原来真的有挂)-哔哩哔哩...
Wpk最新黑科技!wpk德州伙... Wpk最新黑科技!wpk德州伙牌打法(WPK ai辅助)原来是真的有挂(2023已更新)(哔哩哔哩)...
wepoke真的有挂!wepo... wepoke真的有挂!wepoke有插件吗(WePoKe黑科技)总是是真的有挂(有挂详情)-哔哩哔哩...
黑科技辅助(WEpoke)we... 黑科技辅助(WEpoke)wepoke有没有挂(透视)外挂透明挂辅助器(原来真的有挂)-哔哩哔哩1、...
WPK最新黑科技!wpk微扑克... WPK最新黑科技!wpk微扑克真的有辅助吗(WPK ai辅助)都是真的是有挂(2024已更新)(哔哩...