[PD-dev] how do I go about pd_bind()ing multiple symbols to one object and distinguish between them?
Claude Heiland-Allen
claudiusmaximus at goto10.org
Sat Mar 3 11:27:51 CET 2007
Frank Barknecht wrote:
> Hallo,
> Claude Heiland-Allen hat gesagt: // Claude Heiland-Allen wrote:
>
>> I'm writing an external, and I want it to have multiple named receivers
>> that do different things (something that seems trivial for an
>> abstraction but rather tricky for an external).
>
> Does it really have to be multiple receivers?
Yes, because...
> Maybe you could use the
> equivalent of [route] as in
>
> [r GLOBAl]
> |
> [route local-1 local-2 local-3 ...]
>
> Then you would only need one receiver (with pd_bind) and most of the
> rest could be copied from the "route"-code. You would however need to
> use specially formatted messages on the sender-side, that use these
> "tags" to reach their correct destination.
...afaik no GUI objects send these specially formatted messages.
The initial aim is to write an external that does similar to what an
abstraction made up of loads of copies of
[receive $1-balb]--[list prepend balb]--[list trim]--[outlet]
would do, with 'balb' different each time, and only one outlet for the
whole abstraction.
I guess I could implement this as an abstraction with internal messages,
but why should externals be second-class citizens? ;)
And it's also a learning exercise, of course :)
> Ciao
Thanks,
Claude
--
http://claudiusmaximus.goto10.org
More information about the Pd-dev
mailing list