Forums > MaxMSP

info~ inside poly~

Mar 05 2009 | 4:39 am

I’m making a drum machine which uses poly~
Initially my question was how create consecutive #n arguments for each instance of a poly~, for my buffer~, grooveduck2, record~ and a set message.
However simply using #1 still keeps all the buffers separate – as if poly~ is doing it automatically. Except it doesn’t do it for info~ .
Inside all instances all #1’s change to a 0 and all work fine except for info~ – when I open the main patcher i get the following msg.
"#N: bad arguments for message "info~""

I need info~ to retrieve the total length of each file loaded into the buffer, in each instace.

I hope this makes sense.

Mar 05 2009 | 4:52 am

Send a bang to [thispoly~] and it will return the instance number which you can then use to set names of [buffer~]s etc for example using [sprintf]. You will then be able to access [info~] on your buffers from the main patch.


Mar 05 2009 | 6:45 am

Ah, of course. Thanks. I’m guessing when I implement this, I’ll still get the errors before a loadbang fixes the objects’ names though. But as long as it’s functional.


Mar 10 2009 | 12:41 am

pechnatunk wrote on Thu, 05 March 2009 16:45But as long as it’s functional.

Taking that back – is there any way I can get the buffer~, info~, record~ and grooveduck2 to visually update their arguments?

It works fine – maybe now I’m being a little picky.

my poly~ –

— Pasted Max Patch, click to expand. —

main patch –

— Pasted Max Patch, click to expand. —
Mar 10 2009 | 12:47 am

Not without deleting and re-creating the objects with scripting which would be more hassle than it’s worth. If you need to know which [buffer~] is in use you could always connect the "set" message you already have to a message box for visual feedback.


Viewing 5 posts - 1 through 5 (of 5 total)

Forums > MaxMSP