Name of Sketchup Materials (MAC and v2018)

Hi,
I’m creating a dynamic component. I want to choose a material froam a list. As far as I know I know how to do it. The problem is I don’t know the names of the material. When I tried to create a list of materials options I don’t know what to write down.

I have the Sketchup software in Spanish. So I see the name of materials in Spanish. Putting those names on the list does not work.

I guess I need the list of materials in English or identify the file that contains the names of the materials.
Can someone help me?

Thanks in advance.

The colors you want to choose need to be in the ‘In Model’ collection, have ‘web safe’ names like ‘green’ or ‘red’ or you can give a hex number. ( I even think there is a function that lets you give RGB- numbers)

For texures or materials there is only one option:

They need to be in the ‘In Model’ collection. You can use a ‘swatch’ group/component (basically a tiny surface with the texture aplied) which you can hide (nested) in your component.

Thanks for the reply. It was just that. Now I have another problem. It seems that the dynamic components only pass from “parents” to “children”, with nests “father”, “son”, “son-of-son” do not work. can be?

That is basic database: a father can have more sons, but a son can only have one father.
If the father has several jobs for his sons to do, he would have to more specific, or wind up nothing being done…
In SketchUp, it is all about ‘the context’ were you are ‘in’ .

(Dynamic) Components are like little SketchUp files and when they are in the Model, they have a scope (one level up and one level down) If you want more ‘global’ attributes, you can make a ‘swatch’ component with some dummy geometry and apply attributes to this dummy. All components can then refer to the global swatch attributes of this dummy.

Ufff… maybe is to much for me. Anyways I’ll try with your information.

I think the problems are alwats the materials/textures. I can pass atributes (measures and now web colors) from the father to the son and then to the son-of-son. But the problem is textures. I hace tried with a swacht of textures in a group. But this group is on the main level of the DC, maybe I have to put in all the levels or convert in a Conponent.

I’ll tell yoy the results…

Well, almost done!

The problem was very basic. It was not related to nesting (I suppose). The problem was that the component to change had already assigned a specific material. By putting the component (son-of-son) in default color / texture everything has been resolved. Now I can change the son-of-the-son texture from component options.

The “almost” comes because when I go to WINDOW / MODEL INFORMATION / STADISTICS / and pulse “purge not used” the textures that are not active in the component disappear. Even though I have a texture palette within the father component …

That’s a subtle one! SketchUp’s notion of “used” is that the material is currently applied to some face or edge in the model. So the reference from your texture palette evidently doesn’t count when “unused” are purged. A customized Ruby plugin could be written to work around that I suppose, though it would be pretty ad-hoc to your specific situation.

are you mats painted on to faces?

sample models always help…

john

I don’t understand why the textures are not “usted”. I have 3 faces using those textures inside a group, and the group inside the DC… make a small Plugin because this problem is too much for me. Thank you everyone!

What Means ºon the faces? Hoy I can share the example? Wharehouse?

If it is 3MB or smaller, you can upload it directly in a post to this forum using this button at the top of the post edit window 20%20PM

So, here you are… is a “draft” or a “beta version” and it’s in Spanish. But it’s a window and it’s easy to understand. You can change dimensions of total window (HUECO), you can choose the numers of pane (hojas), you can choose the dimensions of ledge, and some materials of the DC…

The swatch is in VENTANA GENERAL V08/PALETA_SWACHT… what is wrong?

thanks in advance!

VENTANA GENERAL v8.skp (269.5 KB)

ah! and I don’t know hoe to organice the “component options” window… so I tried using empty fields…

I poked around in your model via both the normal inspector windows and using Ruby via the Ruby Console. I found some strange things in the materials. I don’t know how they came about or for sure whether they are causing issues, but they seem to have the potential at least for causing confusion. There may also be some bugs in SketchUp’s handling of materials that add to the confusion!

There are a couple of kinds of duplication in the model’s materials collection that perhaps shouldn’t be possible but are there. There are multiple instances of identical colors captured by distinct materials. For example, “white” and “FFFFFF” are different materials that both have the same color. There are also distinct materials with the same name and color, e.g. two versions each of CristalGris, CristalAzul, and CristalVerde. There are distinct materials that seem to be some sort of auto-generated duplicate colors with new names, e.g. CristalGris1 and CristalAzul1 (I have no clue why there isn’t a CristalVerde1).

The Materials window for “Colors in Model” shows 14 user materials plus the default. The Model Info statistics window says there are 17 materials in the model (it never counts the default). Probing via Ruby I also found 17 user-defined materials in the model, of which 4 are not used by any entity in the model (the duplicates of CristalGris and CristalAzul and their renamed variants CristalGris1 and CristalAzul1). These are the 4 that are eliminated if you purge the model.

Turning to your Paleta_Swatch component, I found some oddities in how you have applied materials to it that might produce different results in the DC than you expected. You have put different materials on the front and back of three of the faces in the swatch, and left the front of three of the faces default while painting the back with colors. In the images below I changed the default front color to a shade of tan to make it distinct from the white material), I also labeled the top the faces 1-6 for reference below:

Top of swatch:

Bottom of swatch:

The materials applied to these faces are (front / back):
1 CristalAzul / Material4
2 CristalVerde / Material6
3 CristalGris / Material10
4 default / white
5 default / Material2
6 default / Material3

Those assignments might not do what you expected. For example, none of the 4 materials that get purged are used there and in three cases the front is defaulted.

I hope this analysis helps you sort out what you need to do (I am not an expert on DCs so I won’t pretend that I know what to do with your programming).

uau! many thanks! a lot of information to analyze. Thanks again for your effort.

Part of the problems I think I can solve by creating a new DC from the beginning.

The repetition of materials with the same name (CristalAzul, CristalAzul1 …) I do not know how to explain it. Just when I tried to assign the material to a part of the DC the material appeared in the window with the new name …

As I said, a lot of information (for me) to analyze. As soon as I analyze everything you say, I try to solve my (simple) DC and I tell you how it came out.

Thank you very much again!

PS: I will also upload it to the sketchup wharehouse. After all, it’s a bit of everyone at this time :slight_smile: