[FFmpeg-devel] [RFC] AVFilter Parser
vmrsss
vmrsss
Sun Mar 23 14:23:24 CET 2008
Hi Michael,
On 21 Mar 2008, at 21:02, Michael Niedermayer wrote:
> This one is quite similar to the previous proposals, the main
> difference
> besides a clear definition of things is the feedback/feedforward
> syntax.
> The new syntax avoids the often cited problem with string insertion of
> predefined filter graphs and name colissions.
Yes, we are converging, I like this much better, and I am glad the
idea of user-defined filters has survived. I'll send a few questions
and comments using Vitor's message which followed yours. Two things:
(1) Why not to had a conditional expression on filters parameters to
do the kind of thing Vitor suggested a few emails ago:
> static void init(char *args, AVFilter *ctx) {
> int ang= atoi(args);
> switch (ang) {
> case 90:
> ctx->actual_filter = "transpose,vflip";
> break;
> case 180:
> ctx->actual_filter = "hflip,vflip";
> break;
> case 270:
> ctx->actual_filter = "vflip,transpose";
> break;
> else
> snprintf(ctx->actual_filter, "rotate_slow=%d", ang);
> break;
> }
> }
at the filter-scripting/combination stage? Eg it could be:
filter ::= .... | conditional_filter
conditional_filter ::= case(parameter) of v1 -> filter1 , v2 ->
filter2 , .... , vk -> filterk
where v1, ..., vk are constants and all filter1,...,filterk have the
same number of input and of output streams.
(2) is it OK to send a pdf attachment to the list? just in case one
needs to draw a complex graph...
More information about the ffmpeg-devel
mailing list