2024年1月12日

c# 调用 ffmpeg 获取音频时长

摘要: var arg = "-i \"" + filepath + "\" 2"; TimeSpan duration = TimeSpan.Zero; await FFMpeg.Xamarin.FFmpegLibrary.Run(this.BaseContext, arg, (line) => { Sy 阅读全文

posted @ 2024-01-12 21:33 空明流光 阅读(44) 评论(0) 推荐(0) 编辑

c# 执行命令并获取输出文本

摘要: 1. 一次性全获取(适合快速命令) void Main() { var result = Execute(@"ffmpeg.exe", "-h", 10); result.Dump(); } public string Execute(string filepath,string args, int 阅读全文

posted @ 2024-01-12 20:19 空明流光 阅读(49) 评论(0) 推荐(0) 编辑

导航