From 42d621d131a45fb63571ca6029c2fc4f02811c10 Mon Sep 17 00:00:00 2001 From: Stefano Sabatini Date: Mon, 13 Aug 2012 13:40:01 +0200 Subject: lavfi: add priv class to filter definitions and flags to filter internal options This allows the iteration callbacks to discover the internal class and options, and show them when required. --- libavfilter/avf_concat.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'libavfilter/avf_concat.c') diff --git a/libavfilter/avf_concat.c b/libavfilter/avf_concat.c index 69c0a75dba..208dc3f26c 100644 --- a/libavfilter/avf_concat.c +++ b/libavfilter/avf_concat.c @@ -51,16 +51,19 @@ typedef struct { } ConcatContext; #define OFFSET(x) offsetof(ConcatContext, x) +#define A AV_OPT_FLAG_AUDIO_PARAM +#define F AV_OPT_FLAG_FILTERING_PARAM +#define V AV_OPT_FLAG_VIDEO_PARAM static const AVOption concat_options[] = { { "n", "specify the number of segments", OFFSET(nb_segments), - AV_OPT_TYPE_INT, { .dbl = 2 }, 2, INT_MAX }, + AV_OPT_TYPE_INT, { .dbl = 2 }, 2, INT_MAX, V|A|F}, { "v", "specify the number of video streams", OFFSET(nb_streams[AVMEDIA_TYPE_VIDEO]), - AV_OPT_TYPE_INT, { .dbl = 1 }, 0, INT_MAX }, + AV_OPT_TYPE_INT, { .dbl = 1 }, 0, INT_MAX, V|F }, { "a", "specify the number of audio streams", OFFSET(nb_streams[AVMEDIA_TYPE_AUDIO]), - AV_OPT_TYPE_INT, { .dbl = 0 }, 0, INT_MAX }, + AV_OPT_TYPE_INT, { .dbl = 0 }, 0, INT_MAX, A|F}, { 0 } }; @@ -439,4 +442,5 @@ AVFilter avfilter_avf_concat = { .priv_size = sizeof(ConcatContext), .inputs = (const AVFilterPad[]) { { .name = NULL } }, .outputs = (const AVFilterPad[]) { { .name = NULL } }, + .priv_class = &concat_class, }; -- cgit v1.2.3