私はffmpegの初心者です。FFmpeg avcodec_find_encoderの問題
私の問題は「avcodec_find_encoder(CODEC_ID_H264);」です。 funcは常にnullを返します。
ffmpeg configureは私のubuntuシステムの下にあります。
./ffmpeg
FFmpeg version SVN-r26306, Copyright (c) 2000-2011 the FFmpeg developers
built on Jan 11 2011 10:34:49 with gcc 4.4.5
configuration: --enable-gpl --enable-version3 --enable-nonfree --enable-postproc --enable-libfaac --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libtheora --enable-libvorbis --enable-libvpx --enable-libx264 --enable-libxvid --enable-x11grab
libavutil 50.36. 0/50.36. 0
libavcore 0.16. 0/0.16. 0
libavcodec 52.108. 0/52.108. 0
libavformat 52.92. 0/52.92. 0
libavdevice 52. 2. 3/52. 2. 3
libavfilter 1.72. 0/1.72. 0
libswscale 0.12. 0/0.12. 0
libpostproc 51. 2. 0/51. 2. 0
、設定が--enable-libx264
が含まれているあなたが見ることができるように、私はavcodec_find_encoder(CODEC_ID_H264)だと思います。ヌルではない何かを返す必要があります... 私はこの問題を解決する方法を教えてください?
ps)私のプログラムでavcodec_init()とav_register_all()を呼び出します。
私は私のテストプログラムをコンパイルし、自分の設定した後
gcc -o test test.c -lavutil -lavformat -lavcodec -lx264 -lz -lm
おかげ
有効エンコーダ: libx264 私は./configureからだ - とエンコーダがまだ見つかっていません。 –