summaryrefslogtreecommitdiffstats
path: root/filters
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2018-04-27 15:55:53 +0200
committerJan Ekström <jeebjp@gmail.com>2018-04-29 02:21:32 +0300
commit2a28712b44b0b462a33ee6e91c98e8e19549fede (patch)
tree7ad0c7b8ac366096e77c9fd60d60ce2d6b06a8a2 /filters
parentfff5fda74b4fd151b2fa488f34a55a3c7dda9990 (diff)
downloadmpv-2a28712b44b0b462a33ee6e91c98e8e19549fede.tar.bz2
mpv-2a28712b44b0b462a33ee6e91c98e8e19549fede.tar.xz
f_lavfi: support setting common filter options like "threads"
AVFilterContext instances support some additional AVOptions over the actual filter. This includes useful options like "threads". We didn't support setting those for the "direct" wrapper (--vf=yadif:threads=1 failed). Change this. It requires setting options on the AVFilterContext directly, except the code for positional parameters still needs to access the actual filter's AVOptions.
Diffstat (limited to 'filters')
-rw-r--r--filters/f_lavfi.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/filters/f_lavfi.c b/filters/f_lavfi.c
index 2c01eaf59c..66e045eb2c 100644
--- a/filters/f_lavfi.c
+++ b/filters/f_lavfi.c
@@ -271,7 +271,8 @@ static void precreate_graph(struct lavfi *c, bool first_init)
goto error;
}
- if (mp_set_avopts(c->log, filter->priv, c->direct_filter_opts) < 0)
+ if (mp_set_avopts_pos(c->log, filter, filter->priv,
+ c->direct_filter_opts) < 0)
goto error;
if (avfilter_init_str(filter, NULL) < 0) {