假设我有一部 2 小时的电影,我想在另一个文件中提取/复制音频,比如 01:25:00 和 01:30:00 之间的 5 分钟,有没有办法做到这一点。
该文件为 .avi 格式 -
Format : AVI
Format/Info : Audio Video Interleave
File size : 929 MiB
Duration : 2h 44mn
Overall bit rate mode : Variable
Overall bit rate : 790 Kbps
Writing application : VirtualDubMod 1.5.4.1 (build 2178/release)
Writing library : VirtualDubMod build 2178/release
Video
ID : 0
Format : MPEG-4 Visual
Format profile : Advanced Simple@L5
Format settings, BVOP : 1
Format settings, QPel : No
Format settings, GMC : No warppoints
Format settings, Matrix : Custom
Codec ID : XVID
Codec ID/Hint : XviD
Duration : 2h 44mn
Bit rate : 662 Kbps
Width : 672 pixels
Height : 288 pixels
Display aspect ratio : 2.35:1
Frame rate : 23.976 (23976/1000) fps
Color space : YUV
Chroma subsampling : 4:2:0
Bit depth : 8 bits
Scan type : Progressive
Compression mode : Lossy
Bits/(Pixel*Frame) : 0.143
Stream size : 778 MiB (84%)
Writing library : XviD 1.2.1 (UTC 2008-12-04)
Audio
ID : 1
Format : MPEG Audio
Format version : Version 1
Format profile : Layer 3
Mode : Joint stereo
Mode extension : MS Stereo
Codec ID : 55
Codec ID/Hint : MP3
Duration : 2h 44mn
Bit rate mode : Variable
Bit rate : 115 Kbps
Nominal bit rate : 128 Kbps
Channel(s) : 2 channels
Sampling rate : 48.0 KHz
Compression mode : Lossy
Stream size : 136 MiB (15%)
Alignment : Aligned on interleaves
Interleave, duration : 24 ms (0.58 video frame)
Interleave, preload duration : 485 ms
Writing library : LAME3.98r
Encoding settings : -m j -V 4 -q 2 -lowpass 17 --abr 128
答案1
你有没有尝试过ffmpeg
?就像是
ffmpeg -vn \ # no video
-ss 01:25:00 \ # start offset
-t 300 \ # duration
-i foo.avi bar.mp3
可能会成功。