Community
Hi!
I would like to build a script that takes a file from the computer (i dont care if its ass or mtlx)
and imports it to the hyper shade like this menu tool: .
i know about
cmds.arnoldExportToMaterialX(filename="/path/to/myfile.mtlx", mtl=True)
to export,
but i cannot find an import command.
Thanks!
Solved! Go to Solution.
Solved by Stephen.Blair. Go to Solution.
arnoldImportAss
def arnoldImportShaders(): global defaultOperatorsFolder if defaultOperatorsFolder == "": defaultOperatorsFolder = cmds.workspace(q=True,rd=True, fn=True) objFilter = "ASS File (*.ass);; AXF File (*.axf);; MaterialX File (*.mtlx);; USD File (*.usd *.usda *.usdc)" ret = cmds.fileDialog2(cap='Import Arnold Shaders',okc='Select',fm=1,ff=objFilter,dir=defaultOperatorsFolder) or [] if len(ret): defaultOperatorsFolder = ret[0] cmds.arnoldImportAss(f=ret[0], mask=ai.AI_NODE_SHADER)