diff options
author | Anton Khirnov <anton@khirnov.net> | 2012-05-19 10:37:56 +0200 |
---|---|---|
committer | Anton Khirnov <anton@khirnov.net> | 2012-05-22 21:33:26 +0200 |
commit | 43c7a01e9879640859d32b062ac01700e1333c7a (patch) | |
tree | 041498d8acb9134fce0b26b4d8af986b65b6ceb6 /libavfilter/video.c | |
parent | 88c3b87bd81829d1b7171cb26e5ef5a564dbd96a (diff) | |
download | ffmpeg-43c7a01e9879640859d32b062ac01700e1333c7a.tar.gz |
lavfi: remove avfilter_default_* from public API on next bump.
Those functions are only useful inside filters. It is better to not
support user filters until the API is more stable.
Diffstat (limited to 'libavfilter/video.c')
-rw-r--r-- | libavfilter/video.c | 35 |
1 files changed, 27 insertions, 8 deletions
diff --git a/libavfilter/video.c b/libavfilter/video.c index ad033f3b8f..74b08379bf 100644 --- a/libavfilter/video.c +++ b/libavfilter/video.c @@ -20,6 +20,7 @@ #include "avfilter.h" #include "internal.h" +#include "video.h" #ifdef DEBUG static char *ff_get_ref_perms_string(char *buf, size_t buf_size, int perms) @@ -72,7 +73,7 @@ AVFilterBufferRef *avfilter_null_get_video_buffer(AVFilterLink *link, int perms, /* TODO: set the buffer's priv member to a context structure for the whole * filter chain. This will allow for a buffer pool instead of the constant * alloc & free cycle currently implemented. */ -AVFilterBufferRef *avfilter_default_get_video_buffer(AVFilterLink *link, int perms, int w, int h) +AVFilterBufferRef *ff_default_get_video_buffer(AVFilterLink *link, int perms, int w, int h) { int linesize[4]; uint8_t *data[4]; @@ -149,7 +150,7 @@ AVFilterBufferRef *avfilter_get_video_buffer(AVFilterLink *link, int perms, int ret = link->dstpad->get_video_buffer(link, perms, w, h); if (!ret) - ret = avfilter_default_get_video_buffer(link, perms, w, h); + ret = ff_default_get_video_buffer(link, perms, w, h); if (ret) ret->type = AVMEDIA_TYPE_VIDEO; @@ -164,7 +165,7 @@ void avfilter_null_start_frame(AVFilterLink *link, AVFilterBufferRef *picref) avfilter_start_frame(link->dst->outputs[0], picref); } -void avfilter_default_start_frame(AVFilterLink *inlink, AVFilterBufferRef *picref) +static void default_start_frame(AVFilterLink *inlink, AVFilterBufferRef *picref) { AVFilterLink *outlink = NULL; @@ -189,7 +190,7 @@ void avfilter_start_frame(AVFilterLink *link, AVFilterBufferRef *picref) FF_DPRINTF_START(NULL, start_frame); ff_dlog_link(NULL, link, 0); av_dlog(NULL, " "); ff_dlog_ref(NULL, picref, 1); if (!(start_frame = dst->start_frame)) - start_frame = avfilter_default_start_frame; + start_frame = default_start_frame; if (picref->linesize[0] < 0) perms |= AV_PERM_NEG_LINESIZES; @@ -215,7 +216,7 @@ void avfilter_null_end_frame(AVFilterLink *link) avfilter_end_frame(link->dst->outputs[0]); } -void avfilter_default_end_frame(AVFilterLink *inlink) +static void default_end_frame(AVFilterLink *inlink) { AVFilterLink *outlink = NULL; @@ -239,7 +240,7 @@ void avfilter_end_frame(AVFilterLink *link) void (*end_frame)(AVFilterLink *); if (!(end_frame = link->dstpad->end_frame)) - end_frame = avfilter_default_end_frame; + end_frame = default_end_frame; end_frame(link); @@ -256,7 +257,7 @@ void avfilter_null_draw_slice(AVFilterLink *link, int y, int h, int slice_dir) avfilter_draw_slice(link->dst->outputs[0], y, h, slice_dir); } -void avfilter_default_draw_slice(AVFilterLink *inlink, int y, int h, int slice_dir) +static void default_draw_slice(AVFilterLink *inlink, int y, int h, int slice_dir) { AVFilterLink *outlink = NULL; @@ -304,7 +305,25 @@ void avfilter_draw_slice(AVFilterLink *link, int y, int h, int slice_dir) } if (!(draw_slice = link->dstpad->draw_slice)) - draw_slice = avfilter_default_draw_slice; + draw_slice = default_draw_slice; draw_slice(link, y, h, slice_dir); } +#if FF_API_FILTERS_PUBLIC +AVFilterBufferRef *avfilter_default_get_video_buffer(AVFilterLink *link, int perms, int w, int h) +{ + return ff_default_get_video_buffer(link, perms, w, h); +} +void avfilter_default_start_frame(AVFilterLink *inlink, AVFilterBufferRef *picref) +{ + default_start_frame(inlink, picref); +} +void avfilter_default_end_frame(AVFilterLink *inlink) +{ + default_end_frame(inlink); +} +void avfilter_default_draw_slice(AVFilterLink *inlink, int y, int h, int slice_dir) +{ + default_draw_slice(inlink, y, h, slice_dir); +} +#endif |