ffmpeg 音频波形图
Waveform images have a variety of uses and I've started seeing waveform images overlaying at the bottom of videos. That type of feature seems useful if you want to see identify music in a video or specific spaces in a video which feature action. If you're creating an audio-centric app, you may have a dozen uses for the waveform image.
波形图像有多种用途,我已经开始看到波形图像覆盖在视频底部。 如果您想识别视频中的音乐或视频中具有特定功能的特定空间,则这种类型的功能似乎很有用。 如果要创建以音频为中心的应用程序,则可能有十几种用于波形图像的用途。
You can easily create a waveform image using the amazing ffmpeg utility with a very short command:
您可以使用非常简短的命令使用令人惊叹的ffmpeg实用程序轻松创建波形图像:
ffmpeg -i input -filter_complex "showwavespic=s=640x120" -frames:v 1 output.png
The image you'll get back will look similar to:
您将获得的图像将类似于: