Changing parameter_visibility of ALL pattrstorage-bounded-objects simultaneously

Mark's icon

i have around 100 objects connected to a pattrstorage.
i want to change the parameter visibility of all of them to "hidden" (so that they don't mess with Live's undo history).
the patcher is pretty large and chaotic, so it would take a long time to find all those objects one by one and change their parameter_visibility manually, and it's possible that i may miss or forget some of them.
is there a simple way of addressing/selecting ALL the objects bounded to a pattrstorage?

Max Gardener's icon

There isn't, as far as I am aware. That's not particularly surprising, since the particular attribute is concerned only with an individual pattr object's behavior.

Perhaps the act of going through your large and chaotic patch would provide you with an opportunity to make it less large and chaotic. There are times when sprawl and chaos are not virtues, and this may be one of them. Ask me how I know. :-)

tyler mazaika's icon

Crude, and you'd need to be careful, but it could be faster if you open the .maxpat file in a text editor and search/replace for

"parameter_enable" : 1

Or you can dump the clientlist from your pattrstorage, iterate over each client to send them the message "parameter_enable 0".

-Tyler

SAMPLE_modifyingParameterEnableOnPattr.maxpat
Max Patch

Mark's icon

@tyler :
i figured out how to address them all, using [pattrhub]. send a dump message to the [pattrstorage] as you say, going through a [zl.slice 1] and appending... appending what? that's the problem, hehe.
i can't set parameter_enable to 0 because i need initialization values (without having to flood the patch with [loadmess]), and some of the objects are M4L objects. so, my only option is to set parameter_visibility to hidden, but there is no such attribute! i can only set it from the inspector.

@max gardener:
not too much i can do about tidying up, if i make any more encapsulations then it's just gonna be a bunch of [p dodeca_octapus] with cables going out of the outlets back into the inlets, hehe.
but perhaps it's wise as you say to use the opportunity to get re-acquainted to the mess.


tyler mazaika's icon

Sorry, my mistake, Mark. You were looking just for the visibility, not enablement.

But if recall of initial values is what you need, why do you need that to come via Live's parameter system rather than pattrstorage? Couldn't you save all the client's states in pattrstorage via closebang and recall that when the device re-opens?

Mark's icon

But if recall of initial values is what you need, why do you need that to come via Live's parameter system rather than pattrstorage?

well, your probably right, but some objects were Live objects, so for them i would have to set them to hidden.

anyway i did it manually and of course it took me much less time than all the research i did on how to do it "automatically", hehe, at least i learned some things in the process.