Material assignment & multi-level components

I’m a relatively new user and have been playing around with learning about material assignments, particularly on objects with hierarchy (multi-level groups and components). I’ve been doing a combination of reading docs and experimenting on my own since that type of mix works best for me.

Let’s take the example of components, and specifically multi-level components. I’m seeing that once you open up the top-level component and access one of the sub-components, and assign that sub-component a different material you lose the ability to quickly assign a material via the paint bucket to all the geometry in the entire component. The ‘one-off’ material assignment of that one sub-component wins out all the time after that, and even if you change that material assignment back to the same material assignment of the top level the overall component as a whole is still out of sync. The only way I can figure out how to get back to the original behavior (and get the whole component in sync) is to use ‘Entity Info’ on the sub-component with the different assignment and use the material swatch to assign it the ‘Default Material’. Is this pretty much the correct workflow that most users use for cases such as this?

You can also select the “Default Material” (aka no material) in the material browser.

(If you think of it as no material or undefined material rather than a default material the inheritance from the parent container makes much more sense.)

2018-03-05_08h34_07

Thanks for the info/reply! Yep, I realized that ‘default material’ is essentially ‘no material’ but there has to be a name for it. Yeah, figured you could also do this via mat editor, but thanks for explicitly pointing it out. I guess my mention of ‘entity info’ was due to the fact that I sort of figured I’d be using that to check out objects in a file that perhaps I got from someone else. All in all I think Sketchup’s way of handling this is consistent and rather intuitive and the name ‘default’ doesn’t really get in the way of all of this making a lot of sense.

Btw, this is a bit of a diversion from my question, but it does have to do with the material editor: Doesn’t there need to be some sort of ‘put material in scene / to scene’ command? Over the last week when reading up on dynamic components and material assignments, I’ve come across people describing a weird workflow where you create a few rectangles (to be used as material swatches), assign materials to them to get them in the scene. Then of course you can delete them later, as now the materials are in the scene. Easy enough to do, and trivial but seems rather silly/klunky. Heh…it’s probably on some Sketchup feature wishlist or something…

It’s worth pointing out the natural hierarchy of how geometry takes materials.
A material painted directly on a face will override a material painted on a component and that will override the parent component and so on.
This gives you the ability to set up components that can have easily changed specific material without changing others.
For example a chair component may have all the legs and frame carefully painted with correctly aligned wood textures but the seat cushion colour can be changed with a simple paint of the whole component.
This simple gif roughly shows you what I mean.
Mats

4 Likes

To add a material to the model you need to add it to a drawing element. There’s no other way to load it to the model’s own material list. However, I would not recommenced to assign materials to some temp geometry and then just delete it. As soon as the model is purged the material will be removed unless it is actually used.

On the PC you can add materials to the In Model materials list however without them being applied to faces in the model, they are susceptible to being purged.
add%20mats
I don’t believe it’s an option on the Mac, though.

1 Like

Didin’t know that! I still wouldn’t use it though because of the high risk of the material being purged.

1 Like

Yeah, I overlooked that right-click menu too! Nice tip, thanks. Another way I noticed you can do this that I discovered after I posed the question is this: Open the Secondary Selection Pane and you can drag and drop a material into the ‘In Model’ group. You can do it in both directions, Primary → Secondary and vice versa.

I probably should explain why I asked about this, and admittedly it’s probably a weird corner case. It has to do with creating a material attribute list for a dynamic component. It seems you can’t create a list without materials existing in the model. So…the two tutorials/explanations that I read recently had you create little rectangles, add the materials you wanted in the scene, add the materials to the attribute list, then you can delete the rectangles afterwards. So, I suppose the authors of those tutorials sort of missed the boat in that they could have / should have told the reader to use the two methods here we have discussed- 1) RC menu ‘Add to model’ & 2) drag and drag between the two material editor panes. But you are absolutely correct; the purging of these materials could pose a problem afterwards. You can create the material attribute list for a dynamic component, but if the materials are not in actual use, they can be purged. Then you get some weird results. When you make a material assignment with your via Component Options the Default Material gets assigned if the material is missing, which I suppose is a reasonable way to handle it. Of course you could also say that you would probably not run into this issue because after a material attribute list is created, it would more than likely be used to assign materials before someone purged the file, but you never know.

Thanks for this; it’s definitely consistent with what I’ve been discovering on my own but it’s a very handy model to use to help clarify everything. So, I suppose a way to describe this or look at it is this: ‘local assignments’, win out over assignments that are ‘further away’. In other words, lowest level assignments (e.g. face), win out over assignments made at any higher level…etc. etc. e.g. Sub-component assigments win out over component assignments. I guess it’s a lot like how inheritance works between objects in a hierarchy when you are talking about most, if not all object oriented programming languages.

Box: After playing around with all of this, there is only one thing that doesn’t work as I would have expected, so here’s a question for you: Let’s say that you have 3 instances of a component. Why is it is that a material assignment to one instance doesn’t get propagated to the other two? They are after all the same component. It isn’t until you drill down to the face level that you get propagation. Obviously this question isn’t related to ‘components within components’ hierarchy, but experimenting with that did cause me to have the question. I was playing around with 2 top level components (super-components, I suppose to use the parlance of programming). One of the components contained 3 different sub-components. The other one contained 3 instances of the same sub-component. In both examples, when opening up the outer / top-level component, and assigning a material to one of the sub-components, I noticed that the behavior was the same: Material was assigned to just that component. I thought that was strange, and expected the example that had 3 instances of the same component to all be assigned that material. Then I realized that’s how it works regardless of whether these 3 instances were inside a component or at the top level themselves.

To make changes to a component, you must be inside its wrapper. And until you drill down to the geometry, you aren’t inside the component. The same applies to changing the size of a component with the Scale tool. Scaling one instance of the component has no impact on the other instances (which is what makes the “Dave Method” work)

What’s the easiest way to assign the default material on a Mac?
I can’t find the default material button. Usually I just use the eye drop tool on a default material.

2018-03-05_16-36-31
The easiest way is probably to select it from the Colors in Model.

1 Like

Thanks for the nice succinct answer and the example using the scale tool. Heh…should I be curious as to what the ‘Dave Method’ is all about?

I don’t know if you should be curious but if you are, Box made a nice tutorial.

The phrase “Component” refers to two distinct concepts in SketchUp. There is the Component Definition, which is what you see in the Component Browser and edit when you enter a component. Everything inside a component belong to the definition. There is also the Component Instance, which is what you can see in the 3D model, select and move around. The outer material is a property of the component instance and doesn’t affect other instances referencing the same definition, just as scaling, moving or rotating one instance doesn’t affect the others.

I hope that explanation makes sense.

This topic was automatically closed 91 days after the last reply. New replies are no longer allowed.