How can i use ffmpeg to extract audio from an video every 5 seconds

后端 未结 1 1557
说谎
说谎 2021-01-17 02:07

I need to extract audio from live stream. I want to generate an audio file every 5s.

  • if i use the command ffmpeg -i ***.flv -c:a aac -fs 128k output.aac<
相关标签:
1条回答
  • 2021-01-17 02:27

    Use the segment muxer:

    ffmpeg -i input -map 0:a -f segment -segment_time 5 output_%03d.aac
    

    Add -c copy and use a compatible output container format if you don't want to re-encode.

    0 讨论(0)
提交回复
热议问题