[PD] Newbie: Dollar sign explanation needed

Arif Driessen arifd86 at gmail.com
Sat Oct 25 17:57:46 CEST 2008


Thanks Andy,

Took me a few reads to get my head around but I think I've got it now. Thank
you. :)

(Unfortunately, abstraction was the other word that plagued me, I forgot to
mention)

On Sat, Oct 25, 2008 at 3:43 PM, Andy Farnell <padawan12 at obiwannabe.co.uk>wrote:

>
>
> Hi Afif,
>
> The dollar can have more than one meaning depending on where it is used.
>
> When it is in a message box, like [1 $1 3 $2( it behaves as a substitution
> operator. The nth element of a list will be substituted in the $n position
> and the list message is passed on. So, if a two element list 2, 4 was
> presented to the message box above the result would be a four element
> list 1, 2, 3, 4
>
>
> When it is used in other object boxes in the form $1 or $2 etc it becomes
> the $nth parameter of an abstraction. In other words, if you create an
> abstraction (separate pd file) called [myabs] and create an instance like
> [myabs 10 20 30] then inside  that instance $1 will have a value of 10,
> $2 a value of 20 and $3 will equal 30.
>
> A special use is where you declare $0. This always has a unique value
> per patch (or abstraction instance). It can be used to prefix a variable
> name so that it is unique. For example, arrays must always have a unique
> name. You can create an array called $0-a in an abstraction, and if you
> make several copies of that abstraction the array names will not clash.
>
>
>
>
>
>
>
>
> On Sat, 25 Oct 2008 15:15:28 +0100
> "Arif Driessen" <arifd86 at gmail.com> wrote:
>
> > Hello all.
> >
> > Since starting Uni this year I have gotten really into Pd! I'm still
> reading
> > up and learning the basics but have tried and tried to get my head around
> > the $ parameter (parameter?) but can't
> >
> > Can someone break it down into a very basic explanation so I can take
> that
> > with me to the help files for further understanding.
> >
> > As I see it, $ pretty much denotes storage of a variable, either float or
> > symbol, and works only locally. When added to an object it means: take
> > incoming value and store it under $1 (or $2 e.t.c) for recall later. If
> > there is a series of in incoming values $1 will always refer to the first
> > value and $2 to the second. Sometimes you don't want to recall it, but
> need
> > to tell the object to store a value in order to process it with the very
> > next action, such as in
> >
> > OBJECT: openpanel > MESSAGE: read $1 destination > OBJECT: soundfiler
> >
> > Am I right, somewhat right, or dangerously wrong?
> >
> > And lastly I get this in the Pd window everytime it starts up (Pd
> extended
> > on Mac), is that heathly?:
> >
> > libdir loader $Revision: 1.8 $
> >     written by Hans-Christoph Steiner <hans at at.or.at>
> >     compiled on Jul 29 2008 at 04:03:05
> >     compiled against Pd version 0.40.3.extended
> > /Applications/Pure
> > Data/Pd-extended.app/Contents/Resources/extra/Gem/Gem.pd_darwin:
> > dlopen(/Applications/Pure
> > Data/Pd-extended.app/Contents/Resources/extra/Gem/Gem.pd_darwin, 10):
> > Library not loaded: /usr/X11R6/lib/libfreetype.6.dylib
> >   Referenced from: /Applications/Pure
> > Data/Pd-extended.app/Contents/Resources/extra/Gem/Gem.pd_darwin
> >   Reason: image not found
> > Gem: can't load library
> > libdir_loader: added 'cyclone' to the global objectclass path
> > libdir_loader: added 'zexy' to the global objectclass path
> > libdir_loader: added 'creb' to the global objectclass path
> > libdir_loader: added 'cxc' to the global objectclass path
> > libdir_loader: added 'iemlib' to the global objectclass path
> > libdir_loader: added 'list-abs' to the global objectclass path
> > libdir_loader: added 'mapping' to the global objectclass path
> > libdir_loader: added 'markex' to the global objectclass path
> > libdir_loader: added 'maxlib' to the global objectclass path
> > libdir_loader: added 'memento' to the global objectclass path
> > libdir_loader: added 'mjlib' to the global objectclass path
> > libdir_loader: added 'motex' to the global objectclass path
> > libdir_loader: added 'oscx' to the global objectclass path
> > libdir_loader: added 'pddp' to the global objectclass path
> > libdir_loader: added 'pdogg' to the global objectclass path
> > libdir_loader: added 'pixeltango' to the global objectclass path
> > libdir_loader: added 'pmpd' to the global objectclass path
> > libdir_loader: added 'rradical' to the global objectclass path
> > libdir_loader: added 'sigpack' to the global objectclass path
> > libdir_loader: added 'smlib' to the global objectclass path
> > libdir_loader: added 'toxy' to the global objectclass path
> > libdir_loader: added 'unauthorized' to the global objectclass path
> > libdir_loader: added 'pan' to the global objectclass path
> > libdir_loader: added 'freeverb' to the global objectclass path
> > libdir_loader: added 'hcs' to the global objectclass path
> > libdir_loader: added 'jmmmp' to the global objectclass path
> > libdir_loader: added 'ext13' to the global objectclass path
> > libdir_loader: added 'ggee' to the global objectclass path
> > libdir_loader: added 'flib' to the global objectclass path
> > libdir_loader: added 'ekext' to the global objectclass path
> > libdir_loader: added 'flatspace' to the global objectclass path
> > /Applications/Pure
> > Data/Pd-extended.app/Contents/Resources/extra/pdp.pd_darwin:
> > dlopen(/Applications/Pure
> > Data/Pd-extended.app/Contents/Resources/extra/pdp.pd_darwin, 10): Library
> > not loaded: /usr/X11R6/lib/libX11.6.dylib
> >   Referenced from: /Applications/Pure
> > Data/Pd-extended.app/Contents/Resources/extra/pdp.pd_darwin
> >   Reason: image not found
> > pdp: can't load library
> > /Applications/Pure
> > Data/Pd-extended.app/Contents/Resources/extra/pidip.pd_darwin:
> > dlopen(/Applications/Pure
> > Data/Pd-extended.app/Contents/Resources/extra/pidip.pd_darwin, 10):
> Library
> > not loaded: /usr/X11R6/lib/libX11.6.dylib
> >   Referenced from: /Applications/Pure
> > Data/Pd-extended.app/Contents/Resources/extra/pidip.pd_darwin
> >   Reason: image not found
> > pidip: can't load library
> >
> >
> >
> > ///////////
> >
> > Thanks so much everyone.
> >
>
>
> --
> Use the source
>
> _______________________________________________
> Pd-list at iem.at mailing list
> UNSUBSCRIBE and account-management ->
> http://lists.puredata.info/listinfo/pd-list
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.puredata.info/pipermail/pd-list/attachments/20081025/22702717/attachment.htm>


More information about the Pd-list mailing list