Feature Request : Assign Attributes User Text to objects by Layer

Hello

I would like to request a feature where Attributes can be added to objects by layer, the way we apply Materials to objects by layer. The reason I ask this is that whenever I want assign my custom Attributes.csv to objects, I would have to select each and every object and Import the text or use the Match Attributes command and click an object with an attribute to match.

This is quite cumbersome and time consuming especially if I continue to create new objects that has to have my Attributes. Why can’t we just :

  1. Import/load our Attribute User Text and let Rhino save it in a list or dropdown list in a panel.
  2. Have the additional option to Assign it By Layer, Object, etc.(The way we assign Materials)
  3. Have the option to Filter by Object Type so that my custom Attributes would only be assigned to specific object types of my choosing i.e. a Curve, Point or Brep.

This system can speed up modeling especially when workflows depend on grasshopper attribute extraction (Elefront, Human, Heteroptera etc.)

I hope this request is taken seriously.

Thanks :slight_smile:

1 Like

Hi @attheeast18

It would be good to get a better understanding of your workflow first. You are mentioning the objects need to be processed in grasshopper later on. If that is the case, you could make rules in grasshopper that assign those attributes based on object layer and type.

HI, @Gijs

Thanks for replying. The workflow I’m talking about is starting from native rhino commands. In this environment we all know we can add attributes to objects. But it’s tedious especially when it comes to creating new objects when doodling with curves , breps etc. Creating a new geometry entails me to click on the attributes tab again and click on the match attributes command and then click again to an existing geometry with said attributes. I think a better way is what I mentioned where we can just import all the User Attribute Text files we made; store it in the panel as a dropdown list (Like a material list), then when need be i could just apply it to an object, layer etc. The thing with grasshopper is a few steps down the line. I’m focusing on the native rhino UI.

You can just set up some aliases for that

-_SetUserText ā€œkeyā€ ā€œvalueā€

For instance I have a phase attribute for a different buildings in a masterplan. I just run an alias called ā€˜Phase’ and type the phase number.
-_SetUserText phase

Or if you know you are only going to need lets say 3 phases then you can just make 3 aliases of Phase1, Phase2, Phase3.
-_SetUserText phase 1

This has been working well for us without having to touch grasshopper yet for automating the user text.

I don’t understand what aliases have to do with my request. I’m asking for an extremely easier way where we can apply our User Text Attribute like a material. Like below:

That way, every geometry I create on that layer automatically inherits the User Text Attribute. No more extra clicking, no more Aliases. It’s basically how BIM Softwares operate, where Attributes (Parameters) are stored and are easily accessible and assigned to objects that are filtered either by type, layer, etc.

3 Likes

Attribute texts are object properties. Layers are too in fact. Assigning it based on layer is not 100% straightforward therefore. What would you expect to happen to the attribute once the object moves to another layer?

Then I would expect the attributes to update and inherit the Attribute of the new layer, if it has an assigned attribute. If not, then the User attribute text stays the same.

2 Likes

okay so it remains a layer property and is not applied to the object.
Apparently this is already possible through scripting, but not exposed in the UI.
I’ll add this thread
RH-60908 UserText: Expose Layer UserText in UI

Hi, @Gijs

I saw this thread too last night and it is very similar to what I’m asking for. But I want the the Attribute User Text to be applied to an object. What I mean by this is - say we load our custom Attribute User Text .csv. to Rhino and it will store it like a Standard/Setting. Then we can just select that from a dropdown list in the properties panel as opposed to loading it from a folder in our computer. Then, we apply it ā€œBy Layerā€ which would bring up a check list of the existing layers in our rhino model that we can check (Like the way we apply materials by layer). Then all the Keys and Values would be applied to the object’s Attribute User Text.

But that is a different thing. Before you mentioned that changing the object layer will also change the attribute. That would mean the attribute on the object needs to stay aware that it was applied by layer, and be removed when that object changes layer.

If we would expose the layer attribute text. you could simply lookup the object, check on which layer it is, then check if that layer has an attribute and use that when you start processing your objects (e.g. in gh or script)

Let me try to explain my workflow better. I made a Ramp Creator grasshopper script that takes curves and uses their Attribute User Text as inputs for width, length, height, slope %. As you see below I have made 3 curves and I imported my custom Attributes.

The problem I’m focusing on is the lack of dynamism with the Rhino Attribute User Text. As I’ve explained in earlier posts, to assign these attributes I have to do - Select objects in Layer>Import Attributes>. I have to do this every time I create a new geometry. Now if we have a central attribute that we have the option to apply By Layer. Then I just have to create geometry on a layer and I’m off to the races. I know that every geometry I create from that layer will have those attributes. In the context of my grasshopper script I will only need to change the Values of the Attribute User Text. Now, I understand that there may be problems tracking the changes in attributes. Here is my proposal to fix those.

Dynamic Attributes - Attributes can be assigned in 2 states, ā€œType Attributeā€ and ā€œInstance Attributeā€. Type Attribute means that the Keys and Values are assigned to every object on that layer and is by default ā€œLockedā€ and ā€œUniversalā€ (Meaning we can’t change the Values i.e. Width = 6 can’t be changed unless we ā€œUnlock Itā€). Instance Attribute on the other hand is an ā€œUnlocked Type Attributeā€. I would argue that the current Attribute User Text is already an Instance Attribute because it’s Keys and Values exist on a per instance level(If I change the Key & Value of one object, it doesn’t affect the Key & Value of all the other objects).

This is what I’m proposing. I’m actually taking a lot from Revit. Its based on their Parameter System and is really useful in organizing data as well. I think this needs to be discussed more. It’s hard to explain myself in a few posts. Thanks.

Edit: I forgot to upload the file. Feel free to test out the Grasshopper script. Note that it requires Elefront 5 & Telepathy plugins to work.

Dynamic Attribute User Text.3dm (93.9 KB)
Example for Gijs.gh (65.5 KB)

1 Like

Here is a link explaining the Type parameter and Instance parameter system in revit.

I ve developed a ā€œno input/no frictionā€ LifeCycleAssessment workflow based in Rhino, and using Gh/Python/C# in the background. Its essentially a glorified geometry pipeline (glorified because it processess/simplifies complex geometry into useable quantities for the LCA) connected to another glorified excel calculation file.

The base of that whole tool is essentially a Rhino3D template. Everything depends on layers. Some layers are connected and will send geometry into the script, others arent. My workaround for the moment was to write a layer name, and end after many spaces a LCA. Using that, I can easily pickup the right layers using some gh scripting.

Here s the problem, and here is where I would also need something that the above user suggests:

My colleagues come from all over the world. I cant compell them to use english layer names .. I also cant control their methods of naming the layer. it would be much faster if I could simply write the LCA text identifier on a separate place than in the layer name itself. Attheeast18 proposes to inherit attributes whenever new geometry/objects are drawn on a particular layer. If I could do that it would help me immensely, too.

The key thing here is I want whatever is drawn to automatically inherit an attribute (in this case a text identifier). If I need to ask users to manually enter the text identifier, say in the Name cell, my whole tool loses its purpose of being frictionless.

My workaround works for now, but is flimsy .. Cant we just have a layer dependant, place where we can write some text? We can already assign a material to a layer, why couldnt we assign a text to a layer?

Thanks for the help,

day1savage

Hi day1savage -

The Rhino 9 WIP has a ā€œDescriptionā€ field per layer:

-wim

1 Like

Hi drissmrini,

There is also the Tag property which can go on Rhino objects. This isn’t accessible via the UI (only in materials) but may suit your needs.

1 Like

How are you going to ensure that all your different language users will enter the same text description?

What you can do is assign a User Attribute Text to a layer using a GHPlayer command or a RunPythonScript command and then retrieve it back from any object like this -

Issue is still that your colleagues won’t be able to check which layer has the LCA tag…

What you are asking makes sense. Type and Instance userdata probably best tracks to Rhino Block definitions (Family/Type) and Block instances (Revit Instance).

I would normally map Revit Categories to Rhino Layers. Although, of course certain Revit Families have specific Parameters based on their System Category. The Parameters themselves are not stored on the Category itself.

So, this request seems more to be the ability to have Block Definition Userdata like the ability to have Type parameters.

1 Like