Grasshopper

algorithmic modeling for Rhino

The "Materials" component doesn't work with "CreatAtts" and "Bake" component

Hi,  Andrew.
I've been trying bakeing meshes with attributes below. But it seems that the "Materials" component doesn't work with "CreatAtts" and"Bake" component when it's dealing with some specific type of mesh.There are two different kinds of meshes in the file I attached. I can'tfigure the difference and why it won't work in second condition(below)

Views: 1443

Attachments:

Replies to This Discussion

Hi Turner - I believe the components are working properly, but there are a few things odd with the way you have your materials set up:

In both components, you have the emissive color set to white, which covers up all color appearance in the rendered viewport. An emissive color of black will allow you to see the colors. 

In the upper component, you have the alpha set very very low - which may cause all the materials to look the same. 

The cause of some confusion may be that you are creating two sets of materials with the same names (0.0, 1.0, 2.0 etc) - this will cause materials to be overwritten. You will likely also have better luck giving them a more distinct name, like "MAT_00" "MAT_01" or something along those lines.

Lastly, you may find that there are some old unused materials that are "stuck" in the document and getting in your way somehow... it can be helpful when troubleshooting materials to run the "purge" command in rhino to get rid of these.

Hope some of those suggestions help - and let me know if you are still struggling to get the components to work.

Thanks, Andrew.

I've tried correct the parameters and the way of naming materials that you mentioned. It seems that those meshes which don't work with the components is the cause of the problem.I draw some other meshes in rhino manually and pick them into grasshopper.They all work well with the material component and baking. I double checked to make sure the two sets of meshes have the same parameters with the component. I can't figure out the reason.@_@ 

Those meshes don't work came from another file which I made to form a dataviz system.I rebuild the generation method on the bottom in the gh file i attached. The meshes generated with this method won't work for the material components~

Attachments:

Hi Turner - sorry, I must have pissed your post in January. The definitions you posted work just fine for me - all objects bake with materials without any problem. One issue you may be facing is that your method of creating "Random" material names is actually producing a lot of duplicates between your different definitions. Try deleting all objects from your file, running the "purge" command with materials set to yes, and then disable/reenable the "create materials" component you're having trouble with. You should then be able to bake the meshes and see their correct colors in rendered view. 

RSS

About

Translate

Search

Photos

  • Add Photos
  • View All

© 2024   Created by Scott Davidson.   Powered by

Badges  |  Report an Issue  |  Terms of Service