vlc | branch: master | Thomas Guillem <[email protected]> | Fri May 26 15:57:14 2017 +0200| [6aa25676966d9da65ca929c18b4b021cbcf783c0] | committer: Jean-Baptiste Kempf
filter_chain: load "chain" video filter as a fallback Signed-off-by: Jean-Baptiste Kempf <[email protected]> > http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=6aa25676966d9da65ca929c18b4b021cbcf783c0 --- src/misc/filter_chain.c | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/src/misc/filter_chain.c b/src/misc/filter_chain.c index a3b8a512b0..741a63c9ad 100644 --- a/src/misc/filter_chain.c +++ b/src/misc/filter_chain.c @@ -211,8 +211,18 @@ static filter_t *filter_chain_AppendInner( filter_chain_t *chain, filter->owner.sys = chain; assert( capability != NULL ); + if( name != NULL && filter->b_allow_fmt_out_change ) + { + /* Append the "chain" video filter to the current list. + * This filter will be used if the requested filter fails to load. + * It will then try to add a video converter before. */ + char name_chained[strlen(name) + sizeof(",chain")]; + sprintf( name_chained, "%s,chain", name ); + filter->p_module = module_need( filter, capability, name_chained, true ); + } + else + filter->p_module = module_need( filter, capability, name, name != NULL ); - filter->p_module = module_need( filter, capability, name, name != NULL ); if( filter->p_module == NULL ) goto error; _______________________________________________ vlc-commits mailing list [email protected] https://mailman.videolan.org/listinfo/vlc-commits
