History

lavfi/mp: switch to an AVOptions-based system.

Clément Bœsch committed 13 years ago

Commit 838d8031 parent 70b72ca2 files · +32 −4Browse files

Showing the changes to libavfilter/avfilter.c (1 of 2 files). Show all

Unified · Split

libavfilter/avfilter.c+15−1
@@ -680,7 +680,6 @@ static const char *const filters_left_to_update[] = { · 679 unmodified lines
680680 #endif
681681 "atempo",
682682 "buffer",
683− "mp",
684683 "pan",
685684 "scale",
686685 };
@@ -818,6 +817,21 @@ int avfilter_init_filter(AVFilterContext *filter, const char *args, void *opaque · 131 unmodified lines
818817 goto fail;
819818 #endif
820819 } else {
820+#if CONFIG_MP_FILTER
821+ if (!strcmp(filter->filter->name, "mp")) {
822+ char *escaped;
823+
824+ if (!strncmp(args, "filter=", 7))
825+ args += 7;
826+ ret = av_escape(&escaped, args, ":=", AV_ESCAPE_MODE_BACKSLASH, 0);
827+ if (ret < 0) {
828+ av_log(filter, AV_LOG_ERROR, "Unable to escape MPlayer filters arg '%s'\n", args);
829+ goto fail;
830+ }
831+ ret = process_options(filter, &options, escaped);
832+ av_free(escaped);
833+ } else
834+#endif
821835 ret = process_options(filter, &options, args);
822836 if (ret < 0)
823837 goto fail;

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t