ffmpeg没有找到vcodec libx264

时间:2011-01-19 16:44:34

标签: ffmpeg video-encoding libavcodec

我安装了最新的ffmpeg,但似乎无法找到视频编解码器。我是否需要完全删除ffmpeg并重新运行./configure以便ffmpeg找到视频编解码器?

这是我目前的配置:

FFmpeg version git-f61cbc2, Copyright (c) 2000-2011 the FFmpeg developers built on Jan 18 2011 10:59:49 with gcc 4.0.1 (Apple Inc. build 5465) configuration: --enable-libmp3lame --enable-shared --disable-mmx --arch=x86_64 libavutil 50.36. 0 / 50.36. 0 libavcore 0.16. 1 / 0.16. 1 libavcodec 52.108. 0 / 52.108. 0 libavformat 52.94. 0 / 52.94. 0 libavdevice 52. 2. 3 / 52. 2. 3 libavfilter 1.74. 0 / 1.74. 0 libswscale 0.12. 0 / 0.12. 0

或者,我可以重新运行make命令来包含库吗?

这是我的代码转换代码:

ffmpeg -i ~/Desktop/watercarts.mov -vcodec libx264 -b 250k -bt 50k -acodec libfaac -ab 56k -ac 2 -s 480x320 ~/Desktop/watercartsipod.mp4

错误:

Unknown encoder 'libx264'

提前谢谢。

5 个答案:

答案 0 :(得分:24)

在Ubuntu 10.10(特立独行)中,此编解码器由multiverse存储库中的 libavcodec-extra-53 包提供。

答案 1 :(得分:6)

您需要使用./configure --enable-gpl --enable-libx264进行配置,并且需要最近的x264。

答案 2 :(得分:3)

尝试使用apt-get install进行安装,而不是编译源代码。 它将下载所有必要的编解码库(至少在我的gubuntu上)

答案 3 :(得分:1)

如果你使用的是ubuntu(各种版本),可以使用这个建议用lib x264安装ffmpeg

http://ubuntuforums.org/showthread.php?t=1117283

我个人使用选项“C”。两个简单的命令(复制和粘贴),自动安装正确的版本+库,无需编译,一切正常工作:)

如果您更喜欢编译,那么在同一页面上有“A”选项(它适用于ubuntu 10.10我编译了最后一个版本)。

答案 4 :(得分:1)

我在link to a binary static build上找到了一个this forum,它可以直接使用!

长话短说

$ wget https://johnvansickle.com/ffmpeg/releases/ffmpeg-release-amd64-static.tar.xz
$ tar xvf ffmpeg-release-amd64-static.tar.xz
$ cd ffmpeg-4.1.1-amd64-static

$ ./ffmpeg
ffmpeg version 4.1.1-static https://johnvansickle.com/ffmpeg/
...
相关问题