[PD] variable receive objects?

Frank Barknecht fbar at footils.org
Sat May 12 20:23:14 CEST 2012


Hi Jörn,

On Sat, May 12, 2012 at 01:20:45PM +0200, Jörn Nettingsmeier wrote:
> is there a way to generate a variable receive object similar to a send  
> via message box, whose source is defined at load time?

Attached is a common idiom that can be used in this kind of situation. It
basically works by using one single global send/receive name for everything,
thereby reducing the risk of nameclashes. You could pass $0 as argument to both
abstraction to make it a bit local or better yet: Use [inlet]s to make it as
local as it gets in Pd. Inlets rock!

Then each message you pass along gets prefixed by a certain tag (a number "id"
in the example) in the sender and routed accordingly at the receive side. 
This basically moves the actual receive name into the message you send.

The example requires Pd 0.43 with settable [route] objects, but it's possible
to clone a settable route with [select], check out the sroute.pd example in the
[list]-abs collection.

Ciao
-- 
 Frank Barknecht            Do You RjDj.me?          _ ______footils.org__
-------------- next part --------------
A non-text attachment was scrubbed...
Name: rs-set.pd
Type: application/puredata
Size: 188 bytes
Desc: not available
URL: <http://lists.puredata.info/pipermail/pd-list/attachments/20120512/267167f8/attachment-0003.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: r-set.pd
Type: application/puredata
Size: 408 bytes
Desc: not available
URL: <http://lists.puredata.info/pipermail/pd-list/attachments/20120512/267167f8/attachment-0004.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: s-set.pd
Type: application/puredata
Size: 413 bytes
Desc: not available
URL: <http://lists.puredata.info/pipermail/pd-list/attachments/20120512/267167f8/attachment-0005.bin>


More information about the Pd-list mailing list