`
dmhorse
  • 浏览: 24576 次
  • 来自: ...
最近访客 更多访客>>
社区版块
存档分类
最新评论

ffmpeg compile

阅读更多

http://www.defendingthetruth.com/technology/33167-tutorial-configuring-building-googles-webm-encoder-libvpx-0-9-1-ffmpeg-0-6-a.html

 

Background: 

There are not many tutorials out that show you how to build and configure WebM in FFMPEG 0.6 for Linux (at least that are accessible to anyone other then nerds) so I figured I would write a forum tutorial on how to do it from scratch so that any nerds/hobbyists using Linux can start encoding with the active working encoder 0.9.1 that was just released on 17 Jun, 2010 [1]. Here are some steps you can take to build the encoder and start playing around with WebM. 

Building WebM standalone: 

1. Download WebM from the repositories at Google Code (bz2 archive)
libvpx-0.9.1.tar.bz2 - webm - libvpx 0.9.1 repository snapshot - Project Hosting on Google Code

2. Unzip the archive to a temporary folder or your desktop using the package manager or the terminal

$tar xvf libvpx-0.9.1.tar.bz2 

3. Navigate to the source directory or wherever you unzipped the bz2 archive to $cd /home/USER/libvpx-0.9.1.tar.bz2 for example 

4. Once you are in the directory you then type $./configure this will begin configuring the libvpx 0.9.1 for building the source code, which is written in C programming language. 

5. Once libvpx 0.9.1 has been configured and tested on your machine either i386 or 86_64 ELF build for 32-bit or 64-bit Linux machines you can then begin compiling the source code. If there were problems scroll up to see if you can diagnose what the problem is i.e if you are missing dependencies it should tell you what's needed. 

6. To compile the source code you need to make sure you have root permission. If you do not contact the person who is charge of your system and ask them for the root privileges if you know the password type $sudo make install. This will begin compiling the WebM encoder. 

7. If there were NO compile time errors WebM should be installed on your system. Open a terminal and type $ivfenc -help to run the encoder. If it's not there you may need export your $PATH variable to include the search path for wherever the binary is located on your system. 

8. Now that you have have successfully installed WebM on your system you can now enable it in FFMPEG 0.6 optionally if you would like. Proceed to the next section. 

Enabling WebM in FFMPEG 0.6: 

1. Assuming you have libvpx 0.9.1 installed on your system and you followed the above steps you can now download the FFMPEG 0.6 source. Follow the same steps above to download the source code to FFMPEG 0.6 (tar archive) unzip it to a temporary directory or your desktop. 

2. Navigate to $cd /home/USER/ffmpeg-0.6 directory or wherever you placed the folder. 

3. Once you are in the directory you need to configure FFMPEG 0.6. This is the tricky part. You need to have YASM installed. Do a search for this in the Synaptic Package Manager and install it before you begin to configure FFMPEG (Note: This package is needed to do some complicated assembly linkage in the program before it's built). 

4. Once YASM have been installed begin configuring FFMPEG for WebM support $./configure --enable-libvorbis --enable-libvpx --enable-pthreads . (Note: The last part is necessary for 64-bit Linux distros that have multi-threading instruction sets. If you don't enable it you will get an error!). 

5. Once the configuration has been completed and there were no errors you can then start to build FFMPEG 0.6 with WebM support. Almost every media program in the known universe uses FFMPEG including VLC. Even if you don't use it you can take advantage of it in the future!. Type 
$sudo make install. This will enable VP8 / Vorbis libraries and build them into FFMPEG 0.6. 

6. You are finished! You can now begin encoding with WebM encoder! If you need to know to how encode with WebM I highly recommend you go to Google WebM website and look for "encoding parameters" in the documentation. I will write a tutorial next time on how to do that soon. 

Any trackbacks or questions are welcomed. Please feel free to contact me if there is a problem. Take care and happy hacking!

分享到:
评论

相关推荐

    cross_compile_ffmpeg-modified.sh

    修改过的将大部分github资源转为指向Gitee上的镜像的一个编译脚本,同时外网的下载资源也转化为指向了ftp://localhost/xxxx ,使用前可先自行下载这些...然后替换当中的cross_compile_ffmpeg.sh为本文件,运行,即可。

    ffmpeg-compile-shared-library-for-android, 移植ffmpeg到android,编译可用于jni调用的so库..zip

    FFmpeg 是一个强大的开源多媒体处理框架,用于处理音频和视频数据。它包含了各种工具和库,如 libavcodec(解码器),libavformat(容器格式解析),libavfilter(滤镜系统)以及 libavutil(通用实用工具)。在...

    compile-ffmpeg.sh资源文件

    compile-ffmpeg.sh资源文件啊

    android ffmpeg include 开发ffmpeg需要的头文件

    - 示例配置命令可能如下:`./configure --target-os=linux --arch=arm --cpu=cortex-a8 --enable-cross-compile --prefix=/path/to/output --extra-cflags='-marm -mfloat-abi=softfp' --disable-shared --enable-...

    编译ffmpeg(ffmpeg6.0+android-ndk-r25c)生成的动态链接库.so文件

    --enable-cross-compile \ --target-os=android \ --arch=$TARGET \ --cc=$TOOLCHAIN/bin/clang \ --cxx=$TOOLCHAIN/bin/clang++ \ --cross-prefix=$TOOLCHAIN/bin/$HOST_TAG- \ --sysroot=$NDK_PATH/sysroot...

    ffmpeg 开发环境配置

    官方文档(如`ffmpeg--compile guideon ubuntu.doc`文档)提供了详细的API参考和示例代码,可以帮助你更好地理解和使用FFmpeg。记得经常查看官方更新,以便获取最新的功能和修复。 总之,配置FFmpeg开发环境虽然...

    ffmpeg支持rtmps推流

    在交叉编译OpenSSL时,还应设置好相关的编译选项,例如指定安装路径(--prefix)、交叉编译工具(--cross-compile-prefix)、目标架构(--march)等,并根据芯片架构来修改config和Makefile文件,以避免芯片架构不...

    ffmpeg-4.0.6.tar.gz

    ./configure --prefix=/path/to/install --target-os=linux --arch=arm --cpu=cortex-a55 --enable-cross-compile --cc=arm-linux-gnueabihf-gcc --sysroot=/path/to/sysroot ``` 这里,`--sysroot`参数应指向rk...

    ffmpeg全平台编译

    -enable-cross-compile --enable-shared --disable-doc --enable-gpl --enable-pic --enable-ffmpeg --enable-ffplay --enable-ffprobe --enable-decoder=h264 --enable-encoder=h264 --enable-libx264 ``` 3. **...

    android_ffmpeg配置文件

    --enable-cross-compile \ --sysroot=$NDK/platforms/android-$API/arch-arm/ \ --prefix=/path/to/output/directory \ --extra-cflags="-I$NDK/sources/cxx-stl/gnu-libstdc++/4.9/include -I$NDK/platforms/...

    linux 下ffmpeg安装包

    ./configure --target-os=linux --arch=arm --enable-cross-compile --prefix=/usr/local/arm ``` 这里假设你的目标操作系统是Linux,且已设置好交叉编译路径。 4. 编译和安装: ``` make sudo make install ``` 5....

    android ffmpeg

    --enable-cross-compile \ --sysroot=$ANDROID_NDK/platforms/android-XX/arch-arm/ \ --prefix=/path/to/output \ --extra-cflags="-I$ANDROID_NDK/sources/cxx-stl/gnu-libstdc++/4.9/include -I$ANDROID_NDK/...

    ffmpeg 资源 for android

    --enable-cross-compile \ --sysroot=/path/to/ndk/platforms/android-$API/arch-arm \ --extra-cflags="-I/path/to/freetype/include" \ --extra-ldflags="-L/path/to/freetype/lib" \ --enable-shared \ --disable...

    移植ffmpeg到arm平台.rar

    ./configure --target-os=linux --arch=arm --enable-cross-compile --prefix=/your/install/path --extra-cflags=-I/usr/arm-linux-gnueabihf/include --extra-ldflags=-L/usr/arm-linux-gnueabihf/lib ...

    ffmpeg编译所需环境

    -disable-doc --disable-symver --disable-lzma --disable-bzlib --disable-iconv --disable-zlib --disable-lzo --disable-x86asm --disable-runtime-cpudetect --enable-cross-compile --target-os=mingw32 --arch...

    编译FFmpeg到Android studio中

    --enable-cross-compile \ --target-os=linux \ --arch=arm64 \ --cc=$CROSS_PREFIXgcc \ --cross-prefix=$CROSS_PREFIX \ --nm=$CROSS_PREFIXnm \ --sysroot=$SYSROOT \ --extra-cflags="-Os -fpic $CFLAGS...

    windows下基于MinGW编译ffmpeg之_初级篇_中级篇

    例如,如果只需要编译基本的视频处理功能,可以使用`--enable-cross-compile`、`--target-os=mingw32`等选项。 5. **编译与安装**: 使用`make`命令开始编译,完成后使用`make install`将编译好的库和可执行文件安装...

    android成功编译ffmpeg0.6

    - `--enable-cross-compile` 4. **库依赖**:FFmpeg编译时需要链接一些库,例如SDL、OpenSSL、libiconv等。确保这些库已安装并且配置脚本正确地指定了它们的位置。 5. **JNI接口**:为了在Java层与FFmpeg的C/C++...

    ffmpeg移植android需要的android.mk

    这通常通过执行`configure`脚本完成,设置参数如`--target-os=android`,`--arch=arm`(或对应的目标架构),`--enable-cross-compile`等,以适应Android环境。 5. **JNI接口**:在Android应用中调用FFmpeg库,需要...

    成功交叉编译ffmpeg,sdl

    本话题主要探讨的是如何成功地交叉编译FFmpeg和SDL库,以便在S3c2440这样的ARM架构处理器上运行。FFmpeg是一个强大的开源多媒体处理工具集,包括音视频编码、解码、转换等功能,而SDL(Simple DirectMedia Layer)则...

Global site tag (gtag.js) - Google Analytics