[PD] some issues with dynamic patching

Jonathan Wilkes jancsika at yahoo.com
Sat Mar 23 19:09:59 CET 2013


>________________________________
> From: Jeppi Jeppi <jeppiot at hotmail.com>
>To: "pd-list at iem.at" <pd-list at iem.at> 
>Sent: Saturday, March 23, 2013 9:21 AM
>Subject: [PD] some issues with dynamic patching
> 
>
> 
>Hi all,
>just two questions regarding Pd's messaging system.
>-When I suppres an object by using a find & cut set of messages to pd, I get a "consistency check" error. It is properly erased and nothing wrong seems to happen but, could this error be avoided? Could it be eventually dangerous?
>
>-When I instantiate dynamically an abstraction (not a pd native object, but an abstraction), it does not receive a proper loadbang message. And I should have a way to initialize dynamically created abstractions, taking into account that I instantiate several of them and initialization should be performed indiviually.

If you are using Pd-extended or Pd-l2ork and your abstractions aren't trying to immediately loadbang a message to an outlet when they instantiate,
just use [initbang] and it will work, regardless of whether you are creating all or your abstractions in zero logical time or sporadically at various times.

Unfortunately [initbang] does not exist in Pd-Vanilla, and there is no process to get it into Pd-Vanilla.  If you are dynamically creating all your
abstractions in one go, you can manually send a loadbang to your abstractions once you've created them.  If your abstraction is [foo] then do
this:

[loadbang(
|
[send pd-foo.pd]

That will trigger all the [loadbang] objects inside all the [foo] abstractions that exist in the current Pd instance.

If you are dynamically instantiating your abstractions sporadically, and you want to make sure you're only sending
loadbangs to abstractions that haven't fired one yet (or you want to confine the whole process to the scope of a
canvas and its children, rather than global scope) just use [initbang].  If you really must do it without [initbang]
check the archives for solutions, but do pay attention to how much more knowledge and time those solutions
require than simply instantiating a single [initbang].

-Jonathan

>
>Any hints welcome!
>Josep M 
>_______________________________________________
>Pd-list at iem.at mailing list
>UNSUBSCRIBE and account-management -> http://lists.puredata.info/listinfo/pd-list
>
>
>




More information about the Pd-list mailing list