HumanUi / Human - Automatize selection of components for "SaveStates"

Hello

Using Human Ui and the “SaveStates” component, I was wondering if there was a feature to automatically select all the components for which you want to save the input data.
Example: automatically select all “buttons”, “CheckBox”, “TextBox”…etc

I have a definition with 160 elements of HumanUI to save in the “SaveStates”.
I was wondering if Human can do this?

@andheum

Regards

1 Like

No but you can probably use metahopper to gather all the components you care about into one stream and pipe it into the save state component. Haven’t tested it as I haven’t used save state since we developed the paradigm waaaay back in the day, as I now save all my state information in rhino documents as a general rule. In theory it should work though.

Cheers,
Marc

Yes indeed I can find the output of the humanUi objects using metahopper. Thanks @marcsyp for the idea

But the data type does not match for recording in a savestate.
See the example below, when I connect “textbox” to “savestates”, it works fine.
But when I connect the output of “sametype” to “savestate”, it does not work anymore.

is there a way to get the output of the components selected by metahooper ?

Hi Marc!
Could you please elaborate on how do you save all your state information in rhino documents?
Are the grasshopper parameters saved inside a rhino file rather than the grasshopper itself? Is it through Object Attributes or is there other method?
I’m very curious what is the best method as I’ve been looking for this for a long time.
If creating a tool with Human UI, one wouldn’t want the users to be editing the original tool in the server, but at the same time, would be good to allow them to save somewhere else the parameters states as options.

Any thoughts on this are very appreciated!
Thank you,
Jota

I think he means Grasshopper’s native “Save State” function :

I see. Thanks for it!
What I’ve been striving for, is an option to control the saving/retrieving/deleting parameters directly on the Human UI User Interface without going into the grasshopper window itself.
Unfortunately the Human UI “SaveStates” component is saving on the grasshopper file itself and doesn’t even allow to only delete a selected state (rather deletes entire list).
Perhaps I’ll have to resource to extra plugins in order to export parameter data into a file (json or excel) and later retrieve it again.
Need to keep scavenging on the forum for solutions and if I find an ideal one, I’ll post it here :slight_smile:

1 Like

yes, Grasshopper’s native “SaveState” or Metahooper’s “SaveState” saves backups to the GH file.
I don’t think it’s possible on Metahooper to delete a specific “SaveState”.
You should create a specific discussion on this subject, so that the Metahopper developers or other users can answer you.

Interesting conversation, but no, actually, “Save State” was a solution very early on in the development of HumanUI, and it has its uses for application-level settings that a user may want to set for repeatable states across multiple files, but if you want to save the state of an individual Rhino file and its interaction with your script, you have to save the metadata of the state that you care about in the Rhino file itself.

Unfortunately, I can’t help you with doing that, as the plugin that I built to do all of that (storing data/text/json on objects, layers, and in the document) is private and unreleased. You may be able to hack together a solution using Elefront – but in the beginning, I built my plugin specifically because the event properties of the way Elefront works is not conducive to this kind of control flow in grasshopper, at least the way I needed it to work…

I am looking to do the exact same thing. I can save the parameter data as Attributes and read it after baking but then Human UI interaction no longer work.