我使用alsa录制了一个PCM文件格式的音频文件,并尝试在linux终端中使用Gstream流水线将其编码为WAv文件格式,但我收到了类似警告的警告消息:
erroneous pipeline: no element "audioconvert"
我使用的命令是
--gst-launch filesrc location=file.pcm ! audio/x-raw-int, rate=8000, channels=1, endianness=4321, width=16, depth=16, signed=true ! audioconvert ! audio/x-raw-int, rate=8000, channels=1, endianness=1234, width=16, depth=16, signed=true ! wavenc ! filesink location=file.wav发布于 2017-02-28 02:17:52
如果您仍然收到错误信息,则audioconvert插件安装不正确。为了验证管道的正确性,我已经使用以下管道成功地模拟了下面的任务。考虑将标题更改为代表错误消息的内容,而不是特定的编码任务,因为管道线就可以了。
复制原始音频文件
gst-launch audiotestsrc num-buffers=100 \
! audio/x-raw-int, rate=8000, channels=1, endianness=1234, width=16, depth=16, signed=true \
! audioconvert \
! audio/x-raw-int, rate=8000, channels=1, endianness=4321, width=16, depth=16, signed=true \
! filesink location=foo.pcm..encode it as a WAV
gst-launch filesrc location=foo.pcm \
! audio/x-raw-int, rate=8000, channels=1, endianness=4321, width=16, depth=16, signed=true \
! audioconvert \
! audio/x-raw-int, rate=8000, channels=1, endianness=1234, width=16, depth=16, signed=true \
! wavenc \
! filesink location=foo.wavhttps://stackoverflow.com/questions/41888030
复制相似问题