Pfintime:
Filter:
ddwPatterns/Classes (extension) | Streams-Patterns-Events > Patterns > Constraint

Pfintime
ExtensionExtension

Constrain a value pattern according to the time on the clock

Description

Pfindur limits the total duration of a stream of events, based on the timing stored within each event. This does not work for value patterns (returning numbers, arrays, symbols etc.), because these values contain no internal timing information.

Pfintime limits the duration of a value stream, based on the timing of the parent event pattern. Additionally, if the filtered pattern doesn't yield enough values to fill the required time, Pfintime will output rests until the duration is reached.

Class Methods

.new

Embeds elements of the pattern into the stream until the enclosing event pattern's duration comes close enough to dur.

Examples