I've been watching
video, and trying to recreate the patch in pd. Problem is that pd doesn't seem to have a thispoly~ object. Is there any other way of doing this?-
Is there a pd object similar to Max's thispoly~?
-
He's just using it to get an instance id in this demo. That's pretty easily done, but there are a couple of ways to do it depending on what approach you're using to dynamically instantiate your abstractions.
There is an old Pd object [nqpoly4] (not-quite-poly), and I think a newer one called [polypoly]. I can't find either of them so I built my own demo that shows you a simplified version of what Max's poly~ is doing under the hood to generate an id (except that Max does it in C++ and I do it in Pd itself!)
It's pretty simple really-- just a glorified counter. The stuff inside [expr] just arranges the abstractions in the subpatch in a matrix so that they look nice. I even did a quick hack so you can send a symbol to each instance, or to all of them using a similar syntax to what I saw in that video.
So if you are using an external or abstraction that tries to simulate poly~, it's probably going to give you that instance number as an abstraction argument similar to the way I did it. Check the help patch for whatever you're using, and if it doesn't have a help patch just make your own version of poly~.
-
Thanks for the response. Would you mind posting your patch?
-
Seems to be a PunBB bug.
Just open generator.pd. Open one of the abstractions and you'll see I just loadbang a [f $1] to get the id.
I'd imagine any Pd substitue for poly~ will use a similar trick.