turnoff2
Prev | Orchestra Opcodes and Operators | Next

## turnoff2

turnoff2 — Turn off instance(s) of other instruments at performance time.

## Description

Turn off instance(s) of other instruments at performance time.

## Syntax

    turnoff2 kinsno, kmode, krelease

## Performance

kinsno -- instrument to be turned off (can be fractional) if zero or negative, no instrument is turned off

kmode -- sum of the following values:

- 0, 1, or 2: turn off all instances (0), oldest only (1), or newest only (2)

- 4: only turn off notes with exactly matching (fractional) instrument number, rather than ignoring fractional part

- 8: only turn off notes with indefinite duration (p3 < 0 or MIDI)

krelease -- if non-zero, the turned off instances are allowed to release, otherwise are deactivated immediately (possibly resulting in clicks)

| Note
As a rule of thumb, you should turn off instruments with a higher instrument number than the one where turnoff is called, as doing otherwise might cause initialization issues.

## See Also

turnoff

## Credits

Author: Istvan Varga
2005

New in Csound 5.00

Prev | Up | Next
turnoff | Home | turnon