Get mesh or shape node name

Get mesh or shape node name

LFGFX3D
Enthusiast Enthusiast
784 Views
3 Replies
Message 1 of 4

Get mesh or shape node name

LFGFX3D
Enthusiast
Enthusiast

Hi All,

 

Is there a way to get the mesh name or shape node name as a string value in bifrost? For example, if I have a mesh called "TestCube" with shape node called "TestCubeSphape1" is there a way to get the names into a string in bifrost so it can be used as a file name or prim name in bifrost?

785 Views
3 Replies
Replies (3)
Message 2 of 4

morten.bojsen-hansen
Autodesk
Autodesk

I don't know if this is what you are asking, but you can middle-click drag a Maya shape into the Bifrost graph.

0 Likes
Message 3 of 4

LFGFX3D
Enthusiast
Enthusiast

Thanks for your reply. I'm asking about the Maya mesh or shape node name. Once a mesh is in BF, it is assigned some arbitrary name, for example "pCube1" becomes "mesh1" in BF. I want to get the name of the Maya mesh (pCube1) into BF and be able to use it as a string variable in BF. 

 

The initial goal was to be able to create a simple compound to automate the conversion of Maya meshes to USD meshes. By default, the define_usd_mesh node uses /mesh as the mesh name. I would like to plug a string node to automatically replace the path in the define_usd_mesh node with the name of the mesh in Maya. So if I plug mesh called pCube1 into the compound, the output of the define_usd_mesh node would be a prim with a path "/pCube1" instead of "/mesh." Basically skip the process of manually having to enter the path in the define_usd_mesh node.

 

So far, I have not been able to find a way to get the Maya mesh/shape node name into BF.

Message 4 of 4

morten.bojsen-hansen
Autodesk
Autodesk

There might be some way using Python scripting but I don't personally know how.

0 Likes