検索 - User list
Full Version: Importing Material Assignments from Older HDAs
Root » Solaris and Karma » Importing Material Assignments from Older HDAs
Ted Pallas
hello Solaris team --

I have a tricky issue I've been trying to solve for a few days - I've got several years of HDAs, things like tables and chairs, which all assign materials in SOPs. In general these don't use groups, but rather assign materials before a merge. for example, a chair with a slatted seat and back would have slatMat assigned and legMat assigned, and then the two streams are combined for output.

i've got the material library in LOPs no problem - is there a way to assign it using shop_materialpath?

thanks!
mtucker
Put your HDA inside a SOP Create LOP, and hit the Auto-fill Materials button. This is exactly what happens when you put down a Test Geometry Pig node in the LOP context, since that geometry has two separate materials, using shop_materialpath to specify which parts of the geometry are assigned which material.
Ted Pallas
Nice! This technique works great with HDAs. It would be nice if it would work with Object Merge nodes as well, to get to sop_materialpath from sops.
mtucker
Why wouldn't it work with an Object Merge? The SOP Create LOP doesn't care how the SOP geometry is created, as long as it has a shop_materialpath attribute...
jsmack
mtucker
Why wouldn't it work with an Object Merge? The SOP Create LOP doesn't care how the SOP geometry is created, as long as it has a shop_materialpath attribute...

Is there any chance of the scene import doing this automatically at some point? It has a checkbox for importing 'sop materials', but it's a bit disappointing because it doesn't import sop material assignments.
Ted Pallas
I'm not sure why it doesn't work, but it doesn't seem to work...
mtucker
Open the attached file and hit Auto-fill Materials on the SOP Create LOP. For me it creates the red, green, and blue materials for the three merged objects. Is this not what you're describing? Or does this hip file not work for you?
robp_sidefx
jsmack
Is there any chance of the scene import doing this automatically at some point?

Supporting shop_materialpathvia SceneImport requires enough modifications to the current behaviour that I'm concerned about trying to change it in 18.5 (or below).
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Powered by DjangoBB