[PD] Abstraction arguments: tell apart symbols from floats from no argument at all

Christof Ressi christof.ressi at gmx.at
Sat Dec 22 19:25:41 CET 2018


unfortunately, this doesn't work. missing arguments will become 0 and therefore can't be differentiated from a float arg with with the same value. I think it's only dollarsyms (e.g. "_$1") where the missing argument doesn't become 0.

I think Pd vanilla really needs a mechanism to retreive the creation arguments as a list. personally I quite like $@.

> Gesendet: Samstag, 22. Dezember 2018 um 19:00 Uhr
> Von: "João Pais" <jmmmpais at gmail.com>
> An: pd-list <pd-list at iem.at>, "Peter P." <peterparker at fastmail.com>
> Betreff: Re: [PD] Abstraction arguments: tell apart symbols from floats from no argument at all
>
> another way to do it might be the following. I don't have now the time to  
> test it:
> 
> - loadbang a list with all the arguments (maybe initiated by something  
> like [list $1 $2 $3 ... $16 or whatever])
> - use an abstraction from list-abs to drip the list
> - send the output through a route to test the type
> 
> If you know beforehand that 0s won't be part of the arguments, it will be  
> even easier, just filter out the 0s when detecting the argument type.
> 
> 
> > * Christof Ressi <christof.ressi at gmx.at> [2018-12-22 17:15]:
> >> if you're ok with externals you can also use [dollarg] from iemlib or  
> >> [canvasargs] from iemguts. for a hacky vanilla solution, see attached  
> >> patch. I'm sure there are more ways, this is just one that I remembered.
> > And it is a nice one, Thanks Christof!
> 
> 
> 
> _______________________________________________
> Pd-list at lists.iem.at mailing list
> UNSUBSCRIBE and account-management -> https://lists.puredata.info/listinfo/pd-list
>





More information about the Pd-list mailing list