diff options
author | Fneufneu <fneufneu@xbmc.org> | 2011-06-24 18:16:25 +0200 |
---|---|---|
committer | Fneufneu <fneufneu@xbmc.org> | 2011-06-24 18:16:25 +0200 |
commit | c2c4b7e5288cdd8b75ad49f5256d33525e8c751d (patch) | |
tree | ceb4aea5366e527456c3a8bd0d3d92c2b40fc144 /lib | |
parent | f2f2fdf2c037deecd3d0f089dc47ab5e5a3e9be2 (diff) |
finaly fix av_vsrc_buffer_add_frame with external ffmpeg
Diffstat (limited to 'lib')
-rw-r--r-- | lib/DllAvFilter.h | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/lib/DllAvFilter.h b/lib/DllAvFilter.h index e9722b1673..b81f7147b4 100644 --- a/lib/DllAvFilter.h +++ b/lib/DllAvFilter.h @@ -46,6 +46,19 @@ extern "C" { #elif (defined HAVE_FFMPEG_AVFILTER_H) #include <ffmpeg/avfiltergraph.h> #endif + /* for av_vsrc_buffer_add_frame */ + #if LIBAVFILTER_VERSION_INT >= AV_VERSION_INT(2,8,0) + #include <libavfilter/avcodec.h> + #elif LIBAVFILTER_VERSION_INT >= AV_VERSION_INT(2,7,0) + int av_vsrc_buffer_add_frame(AVFilterContext *buffer_filter, + AVFrame *frame); + #elif LIBAVCODEC_VERSION_INT >= AV_VERSION_INT(53,3,0) + int av_vsrc_buffer_add_frame(AVFilterContext *buffer_filter, + AVFrame *frame, int64_t pts); + #else + int av_vsrc_buffer_add_frame(AVFilterContext *buffer_filter, + AVFrame *frame, int64_t pts, AVRational pixel_aspect); + #endif #else #include "libavfilter/avfiltergraph.h" #endif @@ -67,7 +80,13 @@ public: virtual int avfilter_graph_config(AVFilterGraph *graphctx, AVClass *log_ctx)=0; virtual int avfilter_poll_frame(AVFilterLink *link)=0; virtual int avfilter_request_frame(AVFilterLink *link)=0; +#if LIBAVFILTER_VERSION_INT >= AV_VERSION_INT(2,7,0) + virtual int av_vsrc_buffer_add_frame(AVFilterContext *buffer_filter, AVFrame *frame)=0; +#elif LIBAVCODEC_VERSION_INT >= AV_VERSION_INT(53,3,0) + virtual int av_vsrc_buffer_add_frame(AVFilterContext *buffer_filter, AVFrame *frame, int64_t pts)=0; +#else virtual int av_vsrc_buffer_add_frame(AVFilterContext *buffer_filter, AVFrame *frame, int64_t pts, AVRational pixel_aspect)=0; +#endif virtual AVFilterBufferRef *avfilter_get_video_buffer(AVFilterLink *link, int perms, int w, int h)=0; virtual void avfilter_unref_buffer(AVFilterBufferRef *ref)=0; virtual int avfilter_link(AVFilterContext *src, unsigned srcpad, AVFilterContext *dst, unsigned dstpad)=0; |