[PD-dev] # of instances of an object
Hans-Christoph Steiner
hans at eds.org
Sun Nov 7 19:50:16 CET 2004
So here's my problem:
An object's _free function is called when any instance is deleted. I
need to send a free msg to the MacOS X HID Manager only when the last
instance is deleted. Should I just use a global variable to keep track
of the instances, or can anyone think of a better solution?
.hc
On Nov 6, 2004, at 6:24 PM, Miller Puckette wrote:
> Nope... Pd doesn't track instances of things...
>
> You could write C code to traverse all open canvases to find them, if
> you really wanted to.
>
> cheers
> Miller
>
> On Sat, Nov 06, 2004 at 05:51:23PM -0500, Hans-Christoph Steiner wrote:
>>
>> Is there anyway I can get how many instances of my object are
>> instantiated from Pd? I could keep track of this myself, but I figure
>> if I can get it from Pd, that would be all the better.
>>
>> .hc
>>
>>
>> ______________________________________________________________________
>> ______
>>
>>
>> "[W]e have invented the technology to eliminate scarcity, but we are
>> deliberately throwing it
>> away to benefit those who profit from scarcity."
>> -John Gilmore
>>
>>
________________________________________________________________________
____
¡El pueblo unido jamás será vencido!
More information about the Pd-dev
mailing list