PpolyPar:
Filter:
miSCellaneous_lib/Classes (extension) | Libraries > miSCellaneous > Other patterns

PpolyPar
ExtensionExtension

polyphonic event pattern for an arbitrary number of timed setting streams

Description

This is similar to PmonoPar and allows an arbitrary number of monophonic streams as well as an arbitrary number of differently timed setting streams applied to them in parallel. Each setting action can affect an arbitrary combination of running synths. PpolyPar can be used for polyphonic sources alone as well as in combination with effects.

History: PmonoPar and PpolyPar grew out of discussions on sc-users list, based on an example by Jonatan Liljedahl. Thanks to him, Ron Kuivila, user Monsieur and others for their comments on this – I then suggested classes PsetGroup and PsetFxGroup, which internally used Pgroup. Meanwhile I reworked the implementation, but it's still based on groups. I renamed PsetGroup to PmonoPar – as this makes the functionality more clear – and PsetFxGroup to PpolyPar, as it can be used with or without effect synths, the crucial point is the setting of parallel streams.

Class Methods

.new

Creates a new PpolyPar object.

Arguments:

setPatternPairs

SequenceableCollection of SequenceableCollections containing key/value pairs. Each of the inner collections represents the data of one synth setting stream. Per convention key/value pairs written after a pair with \dur will cause setting, pairs before will not. If keys \midinote, \note or \degree are occuring after \dur, they will be converted to a frequency value, which will be used for setting the arg 'freq'.

Also per convention, if the number of setting streams (the size of setPatternPairs) equals the number of synths (the size of defNames), the settings of stream i will automatically affect synth i. If sizes are unequal, each collection of key/value pairs needs a pair with key \synths and a value. This value can be an Integer, meaning synth i, or a SequenceableCollection of Integers, in which case all of those synths will be affected by the setting. The value can also be a Pattern, so that synths to be set might change from event to event (see examples).

defNames

SequenceableCollection of Symbols or Strings. Names of the SynthDefs to be used for the synths being set. Defaults to #[\default].

order

SequenceableCollection of Integers indicating the order of nodes passed to defNames. Defaults to nil, in that case an order 0, ... , (defNames.size - 1) is assumed, i.e. synth i comes before synth i+1.

offset

Number. Offset to be taken for time-shifting synth inits and streams. Defaults to 1e-6.

Examples

 

Ex.1a: PpolyPar with different instruments

 

Ex.1b: PpolyPar with different instruments and overlapping settings

 

Ex.1c: PpolyPar with different instruments, overlapping settings with array dispatch

 

Ex.2a: PpolyPar with one effect synth

 

Ex.2b: PpolyPar with more effect synths

 

Ex.2c: PpolyPar with more effect synths and streamed setting

 

Ex.2d: PpolyPar with more effect synths, streamed setting and more than one setting stream per synth

 

Ex.2e: PpolyPar with effect chain and streamed fx repatching