Hi. I came up with this as a way to mute a stream of numbers. Basically, I want my notes' names to update automatically as I drag them, but if I change the name manually and hit the little update button, it was renaming them as soon as they were repositioned, since I have a metro going. I have it set up to add the x and y movements of the array to those of the top-level struct, and zero those of the array. Tried stopping the metros, but it quickly got too complicated. I fixed it so it wouldn't change when I updated the position of a manually renamed note, but I found it did the same thing when I switched notes or loaded a new file, because I was using the "change" object. Here's what I did. The "set set $1" message is useful, I'm glad it works. This way the value of the change object is set to the incoming value before the receive is turned back on. Now, though it gives these error message of raty not existing, so I just created two unattached receives, one "raty" and one "nothing", for when one is sent before switching back; but suddenly my application would crash any time I started that loop. I deleted the extraneous receives and it's fine, with the messages again. Is it illegal to send a "receive whatever" message to a non-GUI receive? -Chuckk
Hallo, Chuckk Hubbard hat gesagt: // Chuckk Hubbard wrote:
Hi. I came up with this as a way to mute a stream of numbers. Basically, I
...
Is it illegal to send a "receive whatever" message to a non-GUI receive?
It is not illegal, but personally I consider renaming receives in GUI objects a last resort, as this makes reading and understanding patches much, much harder and can lead to subtle logic errors. For example I had a rather hard time figuring out what your patch is supposed to do by looking at it, until I opened all GUI objects to find the one which has the "raty" or "nothing" receive.
In your patch it is not necessary to make things so complicated. Using a [spigot] makes everything much clearer, at least accoding to my taste.
Also your "set set $1" construct could be replaced by a simple [f] where you can use the cold right inlet to store a number without outputting until a bang arrives at the hot left inlet.
I illustrated this in the attached patch based on your previous mute.pd
Frank Barknecht _ ______footils.org__
_ __latest track: "plak" @ http://footils.org/cms/show/44