StreamSpec:
Filter:
crucial-library/Classes (extension) | Spec | Libraries > crucial > Spec | Streams-Patterns-Events > Patterns > Spec

StreamSpec
ExtensionExtension

datatype specifying that the input or output is stream or pattern

Description

a StreamSpec specifies an input that will be used in a stream or pattern.

It is a HasItemSpec subclass and as such the Stream is specified to return items according to the itemSpec.

The most common use is for InstrSpawner and InstrGateSpawner. These spawn single usually short events just like Patterns, so only an initial value is needed, not a continous control input.

The default control is an IrNumberEditor, though usually you will be more interested in using Patterns as inputs. An IrNumberEditor forces a Synth input of rate \ir and then on each iteration will return the current value of the NumberEditor.

An IrNumberEditor or a Pattern (any object that returns a rate of \stream) will result in the creation of an .ir rate input to the synth function. Then on each spawning, the synth is created and on that .ir rate input is passed in the next value of the stream.

Note that 4.asStream will return an endless stream of 4, and is thus compatible for use as a StreamSpec input.

Instance Methods

.constrain

Arguments:

value

.canAccept

Arguments:

ting

.rate

.defaultControl

Arguments:

val

.minval

.maxval

.clipLo

.clipHi

.color