1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-07-02 17:23:18 +02:00

Drop libavutil/frame.h include again.

Use avcodec_alloc_frame/avcodec_free_frame for older FFmpeg/libav versions
that do not have av_frame_alloc/av_frame_free (when compiling with
--disable-dynamic-loading).
This commit is contained in:
benjamin.drung@gmail.com 2014-05-24 11:01:15 +00:00
parent d139765be4
commit 88b4f52422

View File

@ -38,7 +38,6 @@ extern "C" {
#include <libavcodec/avcodec.h>
#include <libavformat/avformat.h>
#include <libavutil/frame.h>
#include <libavutil/fifo.h>
#include <libavutil/mathematics.h>
@ -61,6 +60,11 @@ extern "C" {
#define CODEC_TYPE_NB AVMEDIA_TYPE_NB
#endif
#if LIBAVCODEC_VERSION_INT < AV_VERSION_INT(55, 45, 101)
#define av_frame_alloc avcodec_alloc_frame
#define av_frame_free avcodec_free_frame
#endif
#ifndef PKT_FLAG_KEY
#define PKT_FLAG_KEY AV_PKT_FLAG_KEY
#endif