xin — Passes variables from a user-defined opcode block,
The xin and xout opcodes copy variables to and from the opcode definition, allowing communication with the calling instrument.
The types of input and output variables are defined by the parameters intypes and outtypes.
Notes | |
---|---|
|
xinarg1, xinarg2, ... - input arguments. The number and type of variables must agree with the user-defined opcode's intypes declaration. However, xin does not check for incorrect use of init-time and control-rate variables.
The syntax of a user-defined opcode block is as follows:
opcode name, outtypes, intypes
xinarg1 [, xinarg2] [, xinarg3] ... [xinargN] xin
[setksmps iksmps]
... the rest of the instrument's code.
xout xoutarg1 [, xoutarg2] [, xoutarg3] ... [xoutargN]
endop
The new opcode can then be used with the usual syntax:
[xinarg1] [, xinarg2] ... [xinargN] name [xoutarg1] [, xoutarg2] ... [xoutargN] [, iksmps]