[PD] sssad key-name in abstractions
Frank Barknecht
fbar at footils.org
Wed Jul 23 11:14:41 CEST 2008
Hallo,
IOhannes m zmoelnig hat gesagt: // IOhannes m zmoelnig wrote:
> Damian Stewart wrote:
> > i suppose the solution is to have a delay that takes an instance name
> > argument, eg [mydelay left], then use that instance name in the sssad
> > key, eg mydelay-$1-delaytime, which will create mydelay-left-delaytime
> > for [mydelay left]. but then the problem remains - if i have a synth
> > that has built-in delay [mydelay left], and i want to have two
> > abstractions of this synth, i'm going to end up with two sets of keys
> > mydelay-left-delaytime. so i need some kind of chained name thing, eg
> > [mysynth squelchy] instantiates [mysynth $1-left], so the sssad key will
> > be mydelay-squelchy-left-delaytime.
>
> the solution is to do it as it is done everywhere else:
> e.g. namepart of URIs: lists.puredata.info
> e.g. OSC-addresses: /squelchy/left/time
>
> >
> > chaining through multiple levels of abstraction like this (which i tend
> > to do when i'm building patches) is going to lead to keynames like
> > mylpf-squelchy-left-sawtooth-lfo-pre-cutoff, for the cutoff frequency of
> > an lfo pre-filter inside the sawtooth generator for the left channel of
> > the 'squelchy' synth. which i suppose isn't a problem, really, it's just
> > a bit messy.
> >
>
> once you've got used to namespaces it is not messy any more.
> at least i prefer setting-files that look like:
> /squelchy/left/time 10
> /squelchy/right/time 20
> /squeezy/left/time 20
And with [sssad] the usual practice is to use an additional $1 inside
of abstractions as prefix to [sssad] objects. Say you have a synth.pd
patch intended to be uses with different settings. Inside of synth.pd
you use these:
[sssad $1/left/time]
[sssad $1/right/time]
Then you can use several different synths like this:
[synth /bass]
[synth /plingy]
[synth /drum]
etc.
Your sssad-savefile will then look like this:
/bass/left/time 12
/bass/right/time 28
/plingy/left/time 2137
/plingy/right/time 17
/drum/left/time 56
/drum/right/time 283
sssad-example.pd contains an example which uses sssliders.pd in this
fashion.
OTOH you can also deliberatly give many [synth]s the same name, if
they should share their settings, for example to make a polyphonic
synth with 12 copies of the same synth voice. Just make enough [synth
/shared] abstractions and control them with [poly] (or use [polypoly])
Ciao
--
Frank Barknecht _ ______footils.org__
More information about the Pd-list
mailing list