scale2 Signal Generators:Linear and Exponential Generators scale2 scale2 Arbitrary signal scaling with optional smoothing. Description Scales incoming value to user-definable range. Similar to scale object found in popular dataflow languages. Syntax kscl scale2 kinput, kmin, kmax[, kimin, kimax][ihtime] Initialisation ihtime -- Optional; Half time value for internal port filter for smoothing. Default is no smoothing. Performance kin -- Input value. Can originate from any k-rate source and should be in the range kimin to kimax. If it is larger than kimax it is treated as kimax, and if less than kimin then it is treated as kimin. kmin -- Minimum value of the resultant scale operation. kmax -- Maximum value of the resultant scale operation. kimin -- Optional; Minimum of the incoming value range, defaulting to zero. kimax -- Optional; Maximum of the incoming value range, defaulting to one. The argument order is minimum before maximum, which differs from scale but it consistent with other opcodes that use a range. Examples Here is an example of the scale2 opcode. It uses the file scale2.csd. Example of the scale2 opcode. See the sections Real-time Audio and Command Line Flags for more information on using command line flags. See also Linear and Exponential Generators Credits Author: &namejohn; after David Akbari December 2020