History

graphparser: simplify condition in avfilter_graph_parse()

Since avfilter_graph_parse() creates the "[in]" inout for the first unlabelled input pad, it is expected that it will create an "[out]" inout for last unlabelled output pad, even in the case where it cannot find any open input pad with that name. This change removes the check on the existence of an open input pad named "out", so it simplifies the checked condition while implementing a more intuitive behavior.

Stefano Sabatini committed 15 years ago

Commit 24207631 parent 2f56a972 files · +2 −2Browse files

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

Unified · Split

libavfilter/graphparser.c+1−1
@@ -389,7 +389,7 @@ int avfilter_graph_parse(AVFilterGraph *graph, const char *filters, · 388 unmodified lines
389389 goto end;
390390 }
391391
392− if (open_inputs && !strcmp(open_inputs->name, "out") && curr_inputs) {
392+ if (curr_inputs) {
393393 /* Last output pad, assume it is "[out]" if not specified */
394394 const char *tmp = "[out]";
395395 if ((ret = parse_outputs(&tmp, &curr_inputs, &open_inputs, &open_outputs,

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