我想制作一个程序,根据 1-2 秒的无声(静音)将一个 MP3 文件分成许多较小的 mp3 文件。 在 C# 中执行此操作的最简单方法是什么?
最佳答案
Bass library .巴斯有你需要的一切。它可以访问、记录和编辑 mp3 等媒体流,允许您在不同的时间点对音量进行采样。它有一个 .net api,因此您可以在 c# 中使用它。不幸的是,如果您将它用于商业应用程序,它确实要花钱,但他们确实提供免费的非商业许可。
Sox是一个命令行工具,可以选择在 n 秒的静音时拆分 mp3。您始终可以使用系统命令从 C# 调用 sox。
其他相关链接。
Ripping a CD to mp3 in C# - third party component or api out there?
Audio Libraries for MP3 editing
How do I merge/join mp3 files with c#
This code shows a way to make a CD ripper in C#. There are APIs from some vendors that allow reading audio CD tracks but it is also possible to do it using APIs that allow low level access to CD drives such as ASPI from Adaptec or IOCTL control codes. The latter method is used in this case, because there is no need to install any third party software, it is completely covered by Win32 API functions.
关于c# - 如何将 mp3 文件拆分成更小的文件?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/1175685/