From bdab614be8df5681b7fbb89abfd08312f2686279 Mon Sep 17 00:00:00 2001 From: "S.N. Hemanth Meenakshisundaram" Date: Thu, 22 Jul 2010 11:12:47 +0000 Subject: Generalize pixel format enum fields to int formats. This is needed to make the libavfilter framework work with audio filters. In particular add a type field to AVFilterLink, change the field types: enum PixelFormat format -> int format in AVFilterBuffer enum PixelFormat *formats -> int *formats in AVFilterFormats enum PixelFormat *format -> int format in AVFilterLink and change the function signatures: AVFilterFormats *avfilter_make_format_list(const enum PixelFormat *pix_fmts); -> AVFilterFormats *avfilter_make_format_list(const int *fmts); int avfilter_add_colorspace(AVFilterFormats **avff, enum PixelFormat pix_fmt); -> int avfilter_add_format(AVFilterFormats **avff, int fmt); AVFilterFormats *avfilter_all_colorspaces(void); -> AVFilterFormats *avfilter_all_formats(enum AVMediaType type); This change breaks libavfilter API/ABI. Patch by S.N. Hemanth Meenakshisundaram |smeenaks|ucsd|edu|. Originally committed as revision 24424 to svn://svn.ffmpeg.org/ffmpeg/trunk --- libavfilter/vf_scale.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'libavfilter/vf_scale.c') diff --git a/libavfilter/vf_scale.c b/libavfilter/vf_scale.c index ebbc575328..c75cf7c87f 100644 --- a/libavfilter/vf_scale.c +++ b/libavfilter/vf_scale.c @@ -83,7 +83,7 @@ static int query_formats(AVFilterContext *ctx) formats = NULL; for (pix_fmt = 0; pix_fmt < PIX_FMT_NB; pix_fmt++) if ( sws_isSupportedInput(pix_fmt) - && (ret = avfilter_add_colorspace(&formats, pix_fmt)) < 0) { + && (ret = avfilter_add_format(&formats, pix_fmt)) < 0) { avfilter_formats_unref(&formats); return ret; } @@ -93,7 +93,7 @@ static int query_formats(AVFilterContext *ctx) formats = NULL; for (pix_fmt = 0; pix_fmt < PIX_FMT_NB; pix_fmt++) if ( sws_isSupportedOutput(pix_fmt) - && (ret = avfilter_add_colorspace(&formats, pix_fmt)) < 0) { + && (ret = avfilter_add_format(&formats, pix_fmt)) < 0) { avfilter_formats_unref(&formats); return ret; } -- cgit v1.2.3