diff options
author | Vitor Sessak <vitor1001@gmail.com> | 2008-04-04 20:09:42 +0000 |
---|---|---|
committer | Vitor Sessak <vitor1001@gmail.com> | 2008-04-04 20:09:42 +0000 |
commit | a6f88fbc8f95064a8851fe66a37cb493988bd382 (patch) | |
tree | 6a6a768661514261963c2ba0c8b407347c0ae67a /libavfilter/avfiltergraph.c | |
parent | 779cc07aa2be707cea8aa3f7040072c49cd68183 (diff) | |
download | ffmpeg-a6f88fbc8f95064a8851fe66a37cb493988bd382.tar.gz |
Give a more meaningful instance name to auto-inserted scaler
Commited in SoC by Vitor Sessak on 2008-04-03 16:51:39
Originally committed as revision 12752 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavfilter/avfiltergraph.c')
-rw-r--r-- | libavfilter/avfiltergraph.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/libavfilter/avfiltergraph.c b/libavfilter/avfiltergraph.c index 45b7a7fcad..1da5b7b912 100644 --- a/libavfilter/avfiltergraph.c +++ b/libavfilter/avfiltergraph.c @@ -54,6 +54,8 @@ AVFilterContext *avfilter_graph_get_filter(AVFilterGraph *graph, char *name) static int query_formats(AVFilterGraph *graph) { int i, j; + int scaler_count = 0; + char inst_name[30]; /* ask all the sub-filters for their supported colorspaces */ for(i = 0; i < graph->filter_count; i ++) { @@ -72,9 +74,12 @@ static int query_formats(AVFilterGraph *graph) if(link && link->in_formats != link->out_formats) { if(!avfilter_merge_formats(link->in_formats, link->out_formats)) { + AVFilterContext *scale; /* couldn't merge format lists. auto-insert scale filter */ - AVFilterContext *scale = - avfilter_open(avfilter_get_by_name("scale"), NULL); + snprintf(inst_name, 30, "auto-inserted scaler %d", + scaler_count); + scale = + avfilter_open(avfilter_get_by_name("scale"),inst_name); if(!scale || scale->filter->init(scale, NULL, NULL) || avfilter_insert_filter(link, scale, 0, 0)) { |