Auto Materialize (change materials and clean up imported CAD)

Auto Materialize is helper tool to automatically assign materials for imported CAD. Often times CAD models don’t have decent colors and might have thousands of geometry items so it is quite tedious to assign materials manually.

Auto Materialize allows to assign materials for items based on their size. The command can be also used to delete for example small items.

In the command you can define 5 different materials and a size limit between the different levels. So setting the Material Level 1 to “red” and Size Limit 1 to “100” means that all the geometry items that can fit in a sphere smaller than 100mm in diameter will be colored red. By defining 4 different size values and 5 materials you can assign different colors for the whole CAD file.

There’s also Delete buttons for different levels. So you can first set small items to red and then delete all those small red items.

Reset Materials button will reset the materials to the originals. This is useful if you use the command only for deleting small items and not actual material color changing.

Decimate factor is used for the Level 1 geometries and it will try to decimate (create the geometry shape with less triangles) if the value is 0…1. Setting value to e.g. 0.95 means that it tries to reduce the data by 5%.

Install the addon by extracting the zip file to My Commands folder. Then restart the application and the “Auto Materialize” will show up in the Wizards on the Modeling tab.

See the attached demo video how to use it.

 

 

AutoMaterialize_2.0.zip (3.5 KB)

How to:

4 Likes

Does this add-on support newer version? like 4.3 which I’m currently using.

Br,
Unnahi

Should work in newer 4.X versions also. I currently have 4.5.

Okay. I’ll try to install it again. I was wondering because I could not get results at all.

-unnahi

It doesn’t work for me, 4.7 version


. please check the clip.

Your component structure seems off. Try importing the model again with different parameters.
Set the Structure option to either Feature or Node. Then the component should not be so scattered.

1 Like

Hi, It works now, Thank you.

New version 2.0 published.
The original post is updated and includes the link to the 2.0 version.

Improvements:

  • Preset option allows quick setup for finding small items. Sets material props so that the tiny geometries are red and the rest are glass1. The other option is Grayscale which set different metallic and black materials.
  • Addon works now with root node and the link nodes of the components. Bluish node selection highlight is overridden in the 3d with the addon material results after clicking the Apply button.
  • minor code clean up and bug fixes
4 Likes