我正在混合两个 wav 音频文件,如下所示
/data/data/com.example.letsjam/app_bin/ffmpeg -i /storage/emulated/0/test1.wav -i /storage/emulated/0/test2.wav -filter:v amerge=inputs=2 /storage/emulated/0/output.wav
输出的 wav 文件仅包含第一个音频的声音。两个音频文件具有相同的采样率和相同的通道数,当然还有相同的格式,即 wav。以下是上述命令的 shell 输出:
shellLine: Input #0, wav, from '/storage/emulated/0/test1.wav':
shellLine: Metadata:
shellLine: encoder : Lavf55.42.100
shellLine: Duration: 00:00:05.02, bitrate: 2048 kb/s
shellLine: Stream #0:0: Audio: pcm_s16le ([1][0][0][0] / 0x0001), 64000 Hz, stereo, s16, 2048 kb/s
shellLine: [wav @ 0x2d89340] Estimating duration from bitrate, this may be inaccurate
shellLine: Guessed Channel Layout for Input Stream #1.0 : stereo
shellLine: Input #1, wav, from '/storage/emulated/0/test2.wav':
shellLine: Duration: 00:00:14.04, bitrate: 1024 kb/s
shellLine: Stream #1:0: Audio: pcm_s16le ([1][0][0][0] / 0x0001), 64000 Hz, 2 channels, s16, 2048 kb/s
shellLine: Output #0, wav, to '/storage/emulated/0/output.wav':
shellLine: Metadata:
shellLine: ISFT : Lavf55.42.100
shellLine: Stream #0:0: Audio: pcm_s16le ([1][0][0][0] / 0x0001), 64000 Hz, stereo, s16, 2048 kb/s
shellLine: Metadata:
shellLine: encoder : Lavc55.66.100 pcm_s16le
shellLine: Stream mapping:
shellLine: Stream #0:0 -> #0:0 (pcm_s16le -> pcm_s16le)
shellLine: Press [q] to stop, [?] for help
shellLine: size= 1254kB time=00:00:05.01 bitrate=2048.2kbits/s
shellLine: video:0kB audio:1254kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 0.007941%
我做错了什么吗?我也试过了,amix
但结果是一样的。生成的输出只有第一个音频文件的声音。任何帮助都将不胜感激!
答案1
您尝试过使用吗audacity
?您可以同步多条音频线路,然后可以混合并导出它们。请参阅此手动输入。