y5gfunc.expr.python2infix¶
python2infix
¶
Python interface to generate infix DSL code, that can be further converted to vapoursynth Expr RPN code.
Refer to this document for documentations about the Python interface.
Classes:
| Name | Description |
|---|---|
DSLExpr |
|
SourceClip |
|
Constant |
|
BuiltInFunc |
|
Functions:
| Name | Description |
|---|---|
varname_toggle |
A context manager to temporarily enable or disable the use of the |
Attributes:
| Name | Type | Description |
|---|---|---|
ExprLike |
TypeAlias
|
|
DSLExpr
¶
Methods:
Attributes:
| Name | Type | Description |
|---|---|---|
dsl |
str
|
|
Source code in y5gfunc/expr/python2infix.py
__bool__
¶
Source code in y5gfunc/expr/python2infix.py
__neg__
¶
SourceClip
¶
Bases: DSLExpr
Methods:
Attributes:
| Name | Type | Description |
|---|---|---|
props |
_PropertyAccessor
|
|
dsl |
str
|
|
Source code in y5gfunc/expr/python2infix.py
__getitem__
¶
Source code in y5gfunc/expr/python2infix.py
access
¶
__bool__
¶
Source code in y5gfunc/expr/python2infix.py
__neg__
¶
BuiltInFunc
¶
Methods:
| Name | Description |
|---|---|
sin |
|
cos |
|
log |
|
exp |
|
sqrt |
|
abs |
|
min |
|
max |
|
clamp |
|
sort |
|
trunc |
|
round |
|
floor |
|
if_then_else |
|
logical_not |
|
bitwise_or |
|
bitwise_xor |
|
bitwise_and |
|
sin
staticmethod
¶
cos
staticmethod
¶
log
staticmethod
¶
exp
staticmethod
¶
sqrt
staticmethod
¶
abs
staticmethod
¶
min
staticmethod
¶
max
staticmethod
¶
clamp
staticmethod
¶
sort
staticmethod
¶
Source code in y5gfunc/expr/python2infix.py
trunc
staticmethod
¶
round
staticmethod
¶
floor
staticmethod
¶
if_then_else
staticmethod
¶
logical_not
staticmethod
¶
bitwise_or
staticmethod
¶
bitwise_xor
staticmethod
¶
varname_toggle
¶
varname_toggle(enable: bool)
A context manager to temporarily enable or disable the use of the varname package.
Disabling this can significantly speed up the generation of complex DSL expressions.
It is disabled by default for performance reasons.
Usage
with varname_toggle(True): # code where varname is enabled ...