30 #define WHITESPACES " \n\t"
44 "Cannot create the link %s:%d -> %s:%d\n",
60 const char *start = *buf;
68 "Bad (empty?) label found in the following: \"%s\".\n", start);
72 if (*(*buf)++ !=
']') {
74 "Mismatched '[' found in the following: \"%s\".\n", start);
95 const char *filt_name,
const char *args,
void *log_ctx)
102 snprintf(inst_name,
sizeof(inst_name),
"Parsed filter %d %s", index, filt_name);
108 "No such filter: '%s'\n", filt_name);
115 "Error creating filter '%s'\n", filt_name);
124 if (!strcmp(filt_name,
"scale") && args && !strstr(args,
"flags")) {
125 snprintf(tmp_args,
sizeof(tmp_args),
"%s:%s",
132 "Error initializing filter '%s' with args '%s'\n", filt_name, args);
156 int index,
void *log_ctx)
167 ret =
create_filter(filt_ctx, graph, index, name, opts, log_ctx);
187 while (*links && strcmp((*links)->name, label))
188 links = &((*links)->next);
200 element->
next = *inouts;
214 "Not enough inputs specified for the \"%s\" filter.\n",
219 *curr_inputs = (*curr_inputs)->
next;
235 "Too many inputs specified for the \"%s\" filter.\n",
258 while (**buf ==
'[') {
293 while (**buf ==
'[') {
300 "No output pad can be associated to link label '%s'.\n",
304 *curr_inputs = (*curr_inputs)->
next;
343 const char *filterchain =
filters;
346 if ((ret =
parse_inputs(&filters, &curr_inputs, &open_outputs, log_ctx)) < 0)
349 if ((ret =
parse_filter(&filter, &filters, graph, index, log_ctx)) < 0)
352 if (filter->
input_count == 1 && !curr_inputs && !index) {
354 const char *tmp =
"[in]";
355 if ((ret =
parse_inputs(&tmp, &curr_inputs, &open_outputs, log_ctx)) < 0)
362 if ((ret =
parse_outputs(&filters, &curr_inputs, &open_inputs, &open_outputs,
369 if (chr ==
';' && curr_inputs) {
371 "Invalid filterchain containing an unlabelled output pad: \"%s\"\n",
377 }
while (chr ==
',' || chr ==
';');
381 "Unable to parse graph description substring: \"%s\"\n",
387 if (open_inputs && !strcmp(open_inputs->
name,
"out") && curr_inputs) {
389 const char *tmp =
"[out]";
390 if ((ret =
parse_outputs(&tmp, &curr_inputs, &open_inputs, &open_outputs,