現在、プログラムが使用する ffmpeg のバージョンをアップグレードしようとしています。これまで使用していたのは ffmpeg 0.8 で、最新バージョンは 1.2 であるため、ジャンプは大きいです。
これらのテストでは、ここで見つけた素晴らしいパッケージを使用しています。
最初に、ffmpeg 1.2 をダウンロードしてビルドしようとしましたが、もちろん、関数と変数が廃止されたか、存在しなくなったことについて、多くの警告とエラーが発生しました。
移行をスムーズにするために、0.8 に最も近い上位バージョンである ffmpeg 1.0 に対してビルドを試みました。以下にリストする警告とエラーのリストを取得しました。
私の質問は次のとおりです。新しいバージョンで古い ffmpeg パラダイム/関数呼び出しを変換するために、これらの移行に役立つガイドはありますか? 私が書いていない多くのコードについて話しているので、行ごとに分析したくないので、古い関数呼び出しを 1 対 1 で新しい関数呼び出し、変数と同じ。
ここに警告とエラーのリストがあります(私はそれをきれいにしたので、エラー/警告ごとに1つのエントリしかありません)
warning: 'AVStream* av_new_stream(AVFormatContext*, int)' is deprecated (declared at /ffmpeg/include/libavformat/avformat.h:1646) [-Wdeprecated-declarations]
warning: 'int avcodec_open(AVCodecContext*, AVCodec*)' is deprecated (declared at /ffmpeg/include/libavcodec/avcodec.h:3569) [-Wdeprecated-declarations]
error: 'avcodec_init' was not declared in this scope
warning: 'int avcodec_encode_video(AVCodecContext*, uint8_t*, int, const AVFrame*)' is deprecated (declared at /ffmpeg/include/libavcodec/avcodec.h:4272) [-Wdeprecated-declarations]
warning: 'AVCodecContext* avcodec_alloc_context()' is deprecated (declared at /ffmpeg/include/libavcodec/avcodec.h:3423) [-Wdeprecated-declarations]
warning: 'int avcodec_decode_audio3(AVCodecContext*, int16_t*, int*, AVPacket*)' is deprecated (declared at /ffmpeg/include/libavcodec/avcodec.h:3852) [-Wdeprecated-declarations]
warning: 'void av_close_input_file(AVFormatContext*)' is deprecated (declared at /ffmpeg/include/libavformat/avformat.h:1622) [-Wdeprecated-declarations]
error: 'av_open_input_file' was not declared in this scope
warning: 'int av_find_stream_info(AVFormatContext*)' is deprecated (declared at /ffmpeg/include/libavformat/avformat.h:1446) [-Wdeprecated-declarations]
error: 'av_set_parameters' was not declared in this scope
error: 'AVFormatContext' has no member named 'file_size'
error: 'URL_WRONLY' was not declared in this scope
error: 'url_fopen' was not declared in this scope
error: 'url_fclose' was not declared in this scope
error: 'SAMPLE_FMT_U8' was not declared in this scope
error: 'SAMPLE_FMT_S16' was not declared in this scope
error: 'SAMPLE_FMT_S32' was not declared in this scope
error: 'SAMPLE_FMT_FLT' was not declared in this scope
error: 'FF_I_TYPE' was not declared in this scope
編集:
私はこれらを見ています...
http://ffmpeg.org/doxygen/0.8/deprecated.html
http://ffmpeg.org/doxygen/0.9/deprecated.html
http://ffmpeg.org/doxygen/ 1.0/deprecated.html
http://ffmpeg.org/doxygen/1.1/deprecated.html
http://ffmpeg.org/doxygen/1.2/deprecated.html
http://ffmpeg.org/doxygen/trunk/deprecated.html