Faster audio waveform rendering by supporting BWF "Peak Envelope Chunk" files?

Hello everyone :slight_smile:

I was wondering if anyone else might be interested in a way to be able to speed up audio-waveform display by being able to pre-generate the level peak information?

I was thinking about the “Peak Envelope Chunk” (EBU Tech 3285s3): This is part of the “BWF” (Broadcast Wave File) specifications, but can be used (and generated) easily as standalone peakfile (eg .lpk).

For example, using ffmpeg to pre-generate the audio waveform/peak information and store it next to the video:

  • myvideo.mp4
  • myvideo.lpk

The command to create such peakfiles using FFmpeg is simple. For example:

$ ffmpeg -i myvideo.mp4 -vn -f wav -write_peak only myvideo.lpk

If Shotcut would support LPK files, we could greatly speed-up certain workflows, and thanks to ffmpeg, the lpk files could be generated from literally any source material. :grin: