Quote:
Originally Posted by fvisagie
As far as I can determine the only expressions accepted by the ternary operator are function calls, be it internal, plugin or script functions. It does not seem to accept assignment statements...
|
From
http://avisynth.org/mediawiki/Grammar:
Quote:
All basic AviSynth scripting statements have one of these forms:
1. variable_name = expression
2. expression
3. return expression
...
An expression can have one of these forms:
1. numeric_constant, string_constant or boolean_constant
2. variable_name or clip_property
3. Function(args)
4. expression.Function(args)
5. expression1 operator expression2
6. bool_expression ? expression1 : expression2
|
The expressions accepted by the ternary operator (ie in expression form 6) are
any of the forms 1-6, so are not limited to function calls (forms 3 and 4).
However, an assignment is not an expression, so can appear only at the start of a statement (statement form 1).