Send infos to different instances of a poly~

Sep 11, 2009 at 1:25am

Send infos to different instances of a poly~

Hi,

A friend of mine advised me to deal with poly~ rather than a set of bpatchers to more CPU efficient but I’m new with this object so sorry for my newbie questions.

1 Is there a way to send infos (bang, ints) to individual instances of a poly~ using the objects send and receive, and not using real “in”s and the “target” message ?
In other words is there a way to have a kind of argument #1 for each instance of poly~ ?

2 Is it possible to use a groove~ inside a poly~ where each groove~ of an instance read a different buffer~ (outside of the poly~) ?

thanks a lot for your help

Florent

#45422
Sep 11, 2009 at 5:30am

In short…yes Smile

Quote:
Is there a way to send infos (bang, ints) to individual instances of a poly~ using the objects send and receive, and not using real “in”s and the “target” message ?
In other words is there a way to have a kind of argument #1 for each instance of poly~ ?

within each instance, a bang to “thispoly~” generates its instance number. You can then use this number to generate specific receives within an instance. For example, say loadbang>>thispoly~ produced “4″ (instance 4). Feed that number into “sprintf set %i_param” connected to a “receive” object with no argument. The sprintf will create the message “set 4_param”, which in turn sets the argument for the receive object essentially creating a “receive 4_param”. If you wish to create unique sends within an instance, look into the “forward” object. Same procedure also works for audio send~/receive~ objects.

Quote:
Is it possible to use a groove~ inside a poly~ where each groove~ of an instance read a different buffer~ (outside of the poly~) ?

yes again. again using bang >> thispoly~ you can change the name of the buffer the groove~ object is using. Check out the help file for more info.

David

#163763
Sep 11, 2009 at 12:20pm

Thanks a lot David for your answer !
I knew the answer was around this thispoly~ object.
I’m just not very confortable with the sprintf messages.
That’s great.
merci beaucoup

Florent

#163764
Sep 11, 2009 at 3:38pm

the alternative is to name buffer/groove/wave/play/.. from
outside the poly, aka “target 3, set sample3″

there are about 25 threads about the same question, so
search the forum for more info.

-110

#163765
Sep 11, 2009 at 3:42pm

…and one could also perhaps have a look at the poly~ tutorials that come with MSP (broad newbie hint).

#163766
Sep 11, 2009 at 5:45pm

Thank you Roman.
I thought I looked enough to the forum, indeed I haven’t.
I am sorry.
In tutorial N°21 about poly~ we learn about getting the instance’s number trough thispoly~ object, but not to have an associated argument for the “receive” object.
I didn’t know the message “sprintf set %i_param” connected to a “receive” object with no argument would do that.
I don’t know C- Language.
I am sorry for my ignorance.
Florent

#163767
Sep 12, 2009 at 7:37am

No worries! poly~ is one of the most powerful and toughest to learn concepts in Max. The fact that you are approaching it means you’re obviously trying. Nevermind the haters and don’t be afraid to ask questions! While this forum is knowledgeable, you have to accept that we can be rude sometimes. Me included.

#163768

You must be logged in to reply to this topic.