[PD] static or class variables in external.

Miller Puckette via Pd-list pd-list at lists.iem.at
Wed Jul 2 19:54:58 CEST 2014


Just declare teh cariable 'static' and it should be the same variable across
all instances.  A (rather complicated) example is the variable 
bonk_filterbanklist in pd/extra/bonk~/bonk~.c (through which all instances
of bonk~ share filter data among them when possible to avoid duplication).

cheers
Miller

On Wed, Jul 02, 2014 at 12:24:00PM -0500, Rafael Vega via Pd-list wrote:
> Hi. I'm writing an external and I would like to re-use a variable across
> instances of the external. Is this possible? how?
> Thanks :)
> 
> -- 
> Rafael Vega
> email.rafa at gmail.com

> _______________________________________________
> Pd-list at lists.iem.at mailing list
> UNSUBSCRIBE and account-management -> http://lists.puredata.info/listinfo/pd-list




More information about the Pd-list mailing list