Assign material by [block attribute text] to geometry inside block

It would be nice if one could assign materials by block attribute text to selected geometry inside a block. It should be possible to use any number of attributes (materials), otherwise, one can just use the object parent material.

The other UI part of the puzzle, on outside of the block, is under Attribute User Text, I think simple text entry would suffice, no need for drop-down menus with materials etc. (they slow down the workflow anyway). But text autocomplete from the list of materials present in document would be nice.

wishlist rhino9

I think this is an excellent idea, and the same approach would even work for decals.

Imagine that you create a cylinder with a decal partially wrapped around it, then the cylinder is inserted as a block into another model. Currently the decal is fixed, so visual variations of the same object is only possible by

  • either creating a second copy of the source cylinder with a different decal or
  • not adding a decal to the block but defining it in the higher-level model for each copy of the block, one by one (if there are hundreds of copies of the block instance, then the decal would have to be added hundreds of times, with the right mapping, texture, etc.)

I even reported this as an issue: RH-90838

With this idea, the decal could be placed in a single block definition, the decal’s texture could be set to “Instance-specific Material” and then, for each block instance, a specific key-value pair could be used to control the decal’s appearance. So a single block instance could be rendered in numerous visual varieties.

This approach would also work for multiple decals in a single block instance, and any number of nesting levels of nested block definitions.