aboutsummaryrefslogtreecommitdiffstats
path: root/libavfilter
diff options
context:
space:
mode:
authorAnton Khirnov <anton@khirnov.net>2013-03-31 12:17:07 +0200
committerAnton Khirnov <anton@khirnov.net>2013-04-11 20:38:23 +0200
commit111367263af41c88a44bd763ceefc11d53a7f655 (patch)
treea9f9b4f8e01cdb636737ceaedb8f1f3ac76f7341 /libavfilter
parentc2c9801bc9bce688d51d1a96f5f3ea93933e2dee (diff)
downloadffmpeg-111367263af41c88a44bd763ceefc11d53a7f655.tar.gz
lavfi: add AVFilterContext.graph.
It will be useful in the following commits.
Diffstat (limited to 'libavfilter')
-rw-r--r--libavfilter/avfilter.h2
-rw-r--r--libavfilter/avfiltergraph.c4
2 files changed, 6 insertions, 0 deletions
diff --git a/libavfilter/avfilter.h b/libavfilter/avfilter.h
index 94d5d6152b..b37b74f2ce 100644
--- a/libavfilter/avfilter.h
+++ b/libavfilter/avfilter.h
@@ -458,6 +458,8 @@ struct AVFilterContext {
unsigned nb_outputs; ///< number of output pads
void *priv; ///< private data for use by the filter
+
+ struct AVFilterGraph *graph; ///< filtergraph this filter belongs to
};
/**
diff --git a/libavfilter/avfiltergraph.c b/libavfilter/avfiltergraph.c
index 828b462550..969d958541 100644
--- a/libavfilter/avfiltergraph.c
+++ b/libavfilter/avfiltergraph.c
@@ -73,6 +73,8 @@ int avfilter_graph_add_filter(AVFilterGraph *graph, AVFilterContext *filter)
graph->filter_count = graph->nb_filters;
#endif
+ filter->graph = graph;
+
return 0;
}
#endif
@@ -121,6 +123,8 @@ AVFilterContext *avfilter_graph_alloc_filter(AVFilterGraph *graph,
graph->filter_count = graph->nb_filters;
#endif
+ s->graph = graph;
+
return s;
}