subinstr Instrument Control:Subinstrument Control subinstr subinstr Creates and runs a numbered instrument instance. Description Creates an instance of another instrument and is used as if it were an opcode. Syntax a1, [...] [, a8] subinstr instrnum [, p4] [, p5] [...] a1, [...] [, a8] subinstr "insname" [, p4] [, p5] [...] Initialization instrnum -- Number of the instrument to be called. insname -- A string (in double-quotes) representing a named instrument. Performance a1, ..., a8 -- The audio output from the called instrument. This is generated using the signal output opcodes. p4, p5, ... -- Additional input values the are mapped to the called instrument p-fields, starting with p4. The called instrument's p2 and p3 values will be identical to the host instrument's values. While the host instrument can control its own duration, any such attempts inside the called instrument will most likely have no effect. See Also event, schedule, subinstrinit Examples Here is an example of the subinstr opcode. It uses the file subinstr.csd. Example of the subinstr opcode. See the sections Real-time Audio and Command Line Flags for more information on using command line flags. Here is an example of the subinstr opcode using a named instrument. It uses the file subinstr_named.csd. Example of the subinstr opcode using a named instrument. See also Sub-instrument Control Credits New in version 4.21