ffmpeg:如何使音频流静音
通过将
ffmpeg_silence_af.txt
-af "volume=-60dB"添加到你的 ffmpeg 命令中,你可以使音频流基本静音。此命令将音频流的音量降低 60 分贝,即降低 99.9%。
请注意,应用 -af 等音频过滤器时不能使用 -c:a copy。相反,你需要使用例如 -c:a aac -b:a 128k 或你选择的任何其他编解码器和比特率重新编码音频流。
完整示例命令:
将视频重新编码为 baseline 并使音频流静音:
ffmpeg_silence_example.sh
ffmpeg -i video.mkv -threads 8 -c:v libx264 -profile:v baseline -level:v 4.0 -af "volume=-60dB" -c:a aac -b:a 128k video.mp4Check out similar posts by category:
Audio/Video
If this post helped you, please consider buying me a coffee or donating via PayPal to support research & publishing of new posts on TechOverflow