我正在尝试使用FFMPEG将AMR音频文件转换为MP3.我在Windows 7主机上使用VBox运行Ubuntu 10.10并且我已经安装了ffmpeg运行sudo apt-get install ffmpeg
我已经有一个我以前记录过的AMR文件所以我运行了命令:ffmpeg -i myfile.amr myfile.mp3
转换失败,跟踪如下:
FFmpeg version 0.6-4:0.6-2ubuntu6, Copyright (c) 2000-2010 the FFmpeg developers built on Oct 5 2010 22:35:47 with gcc 4.4.5 configuration: --extra-version=4:0.6-2ubuntu6 --prefix=/usr --enable-avfilter --enable-avfilter-lavf --enable-vdpau --enable-bzlib --enable-libgsm --enable-libschroedinger --enable-libspeex --enable-libtheora --enable-libvorbis --enable-vaapi --enable-pthreads --enable-zlib --enable-libvpx --disable-stripping --enable-runtime-cpudetect --enable-gpl --enable-postproc --enable-x11grab --enable-libdc1394 --enable-shared --disable-static WARNING: library configuration mismatch libavutil configuration: --extra-version=4:0.6-2ubuntu6 --prefix=/usr --enable-avfilter --enable-avfilter-lavf --enable-vdpau --enable-bzlib --enable-libgsm --enable-libschroedinger --enable-libspeex --enable-libtheora --enable-libvorbis --enable-vaapi --enable-pthreads --enable-zlib --enable-libvpx --disable-stripping --enable-runtime-cpudetect --enable-gpl --enable-postproc --enable-x11grab --enable-libdc1394 --shlibdir=/usr/lib/i686/cmov --cpu=i686 --enable-shared --disable-static --disable-ffmpeg --disable-ffplay libavcodec configuration: --extra-version=4:0.6-2ubuntu6 --prefix=/usr --enable-avfilter --enable-avfilter-lavf --enable-vdpau --enable-bzlib --enable-libgsm --enable-libschroedinger --enable-libspeex --enable-libtheora --enable-libvorbis --enable-vaapi --enable-pthreads --enable-zlib --enable-libvpx --disable-stripping --enable-runtime-cpudetect --enable-gpl --enable-postproc --enable-x11grab --enable-libdc1394 --shlibdir=/usr/lib/i686/cmov --cpu=i686 --enable-shared --disable-static --disable-ffmpeg --disable-ffplay libavformat configuration: --extra-version=4:0.6-2ubuntu6 --prefix=/usr --enable-avfilter --enable-avfilter-lavf --enable-vdpau --enable-bzlib --enable-libgsm --enable-libschroedinger --enable-libspeex --enable-libtheora --enable-libvorbis --enable-vaapi --enable-pthreads --enable-zlib --enable-libvpx --disable-stripping --enable-runtime-cpudetect --enable-gpl --enable-postproc --enable-x11grab --enable-libdc1394 --shlibdir=/usr/lib/i686/cmov --cpu=i686 --enable-shared --disable-static --disable-ffmpeg --disable-ffplay libavdevice configuration: --extra-version=4:0.6-2ubuntu6 --prefix=/usr --enable-avfilter --enable-avfilter-lavf --enable-vdpau --enable-bzlib --enable-libgsm --enable-libschroedinger --enable-libspeex --enable-libtheora --enable-libvorbis --enable-vaapi --enable-pthreads --enable-zlib --enable-libvpx --disable-stripping --enable-runtime-cpudetect --enable-gpl --enable-postproc --enable-x11grab --enable-libdc1394 --shlibdir=/usr/lib/i686/cmov --cpu=i686 --enable-shared --disable-static --disable-ffmpeg --disable-ffplay libavfilter configuration: --extra-version=4:0.6-2ubuntu6 --prefix=/usr --enable-avfilter --enable-avfilter-lavf --enable-vdpau --enable-bzlib --enable-libgsm --enable-libschroedinger --enable-libspeex --enable-libtheora --enable-libvorbis --enable-vaapi --enable-pthreads --enable-zlib --enable-libvpx --disable-stripping --enable-runtime-cpudetect --enable-gpl --enable-postproc --enable-x11grab --enable-libdc1394 --shlibdir=/usr/lib/i686/cmov --cpu=i686 --enable-shared --disable-static --disable-ffmpeg --disable-ffplay libswscale configuration: --extra-version=4:0.6-2ubuntu6 --prefix=/usr --enable-avfilter --enable-avfilter-lavf --enable-vdpau --enable-bzlib --enable-libgsm --enable-libschroedinger --enable-libspeex --enable-libtheora --enable-libvorbis --enable-vaapi --enable-pthreads --enable-zlib --enable-libvpx --disable-stripping --enable-runtime-cpudetect --enable-gpl --enable-postproc --enable-x11grab --enable-libdc1394 --shlibdir=/usr/lib/i686/cmov --cpu=i686 --enable-shared --disable-static --disable-ffmpeg --disable-ffplay libpostproc configuration: --extra-version=4:0.6-2ubuntu6 --prefix=/usr --enable-avfilter --enable-avfilter-lavf --enable-vdpau --enable-bzlib --enable-libgsm --enable-libschroedinger --enable-libspeex --enable-libtheora --enable-libvorbis --enable-vaapi --enable-pthreads --enable-zlib --enable-libvpx --disable-stripping --enable-runtime-cpudetect --enable-gpl --enable-postproc --enable-x11grab --enable-libdc1394 --shlibdir=/usr/lib/i686/cmov --cpu=i686 --enable-shared --disable-static --disable-ffmpeg --disable-ffplay libavutil 50.15. 1 / 50.15. 1 libavcodec 52.72. 2 / 52.72. 2 libavformat 52.64. 2 / 52.64. 2 libavdevice 52. 2. 0 / 52. 2. 0 libavfilter 1.19. 0 / 1.19. 0 libswscale 0.11. 0 / 0.11. 0 libpostproc 51. 2. 0 / 51. 2. 0 [amr @ 0x8538420]Estimating duration from bitrate, this may be inaccurate Input #0, amr, from '/home/octavius/share/1-aloalodwd.amr': Duration: N/A, bitrate: N/A Stream #0.0: Audio: amrnb, 8000 Hz, 1 channels, flt File '/home/octavius/share/1-aloalodwd.mp3' already exists. Overwrite ? [y/N] y Output #0, mp3, to '/home/octavius/share/1-aloalodwd.mp3': Stream #0.0: Audio: 0x0000, 8000 Hz, 1 channels, flt, 64 kb/s Stream mapping: Stream #0.0 -> #0.0 Encoder (codec id 86017) not found for output stream #0.0 octavius@octavius-VirtualBox:~$
所以根据这个线程ffmpeg的指示:将仅音频flv转换为swf我运行命令sudo apt-get install ffmpeg libavcodec-extra-52
来安装额外的库,我仍然有同样的问题.还有其他想法吗?
更新:也在他们链接到这个网站的线程,以使其工作http://stephenjungels.com/jungels.net/articles/ffmpeg-howto.html遵循所有步骤,它仍然无法正常工作
唉,关于无用的ubuntu软件包的那些无用的ubuntu问题.
使用FFMPEG将AMR转换为MP3
ffmpeg -i audio1.amr -ar 22050 audio1.mp3
这会将audio1.amr
文件转换为audio1.mp3
22.05 Khz的音频
我按照这里的说明解决了这个问题http://pasindudps.blogspot.com/2010/12/compiling-ffmpeg-in-ubuntu-1010.html这样做我没有问题做音频转换
编辑:我发布的链接现在已经死了,这是Linux系统的另一个链接http://linuxers.org/tutorial/how-install-ffmpeg-linux这里是Mac OS X的另一个http://jungels.net/articles/ ffmpeg的-howto.html
更新的答案:
由于我不得不使用这个解决方案似乎变得更容易.在Mac OS上,您只需使用Homebrew:
brew install ffmpeg --with-fdk-aac --with-ffplay --with-freetype --with-libass --with-libquvi --with-libvorbis --with-libvpx --with-opus --with-x265
只能从存储库安装的Linux系统:
sudo apt-get install ffmpeg
要么
su -c 'yum install ffmpeg'
该FFMPEG网站现在有更新的文档和下载适用于Windows,Mac或Linux为好; 如果需要任何进一步的信息.