How do I add stl meshes and colours to an existing usd?

Hi I have an existing usd robot that is working fine in omniisaacgymnvs and of the correct porportions
I have the stl files for the 3d printed version
how can I add these to the usd file for the robot to visualise it better in omniverse?
i wanted to be able to colour the different meshes and have several meshes of different colours for each rigid body

Hi there, please check out the CAD importer tool available in omniverse: CAD Converter — Omniverse Extensions latest documentation to import the STL into USD. Once imported, you can add it to your existing asset’s USD stage and drag the individual meshes under the corresponding rigid bodies as their visual bodies.

1 Like

Thanks @kellyg I had tried doing it previously from the import menu and failed but it did work from the content browser. The meshes were off-centre due to a fault in my stl exporter but I was able to fix this with meshlab.
May seem a really basic question but how can I set the colors of the meshes with the least memory allocation…? I couldn’t understand how to create a simple custom material…

depending on the complexity of the material, the quickest way to get material into your scene and onto your meshes could be using some of the materials shipped with OV. you can access it via Window > Browsers > Materials:

image


you can see the variety you can choose from within ‘metal’ section alone

to apply any to your mesh, simply drag and drop onto prims where you’d like that specific material. some of these come with predetermined params for additional tweaking.

alternatively, you can create a material from scratch, which may allow you to control the material/shader complexity, which could have direct impact on the viewport perf. you can review the material overview video from the doc:

https://docs.omniverse.nvidia.com/materials-and-rendering/latest/materials.html#overview

thanks @simplychenable this is exactly what I needed re. material from scratch…

1 Like

@Simplychenable and @kellyg I was able to use the cad importer using .obj files. Although isaacsim accepts obj’s directly dropped onto the stage this throws errors in omniisaacgymenvs which would only accept the converted usd’s. I was able to take the simple generated materials from the converter and drop them into a robot “Looks” folder so I didn’t have to build my own. The mesh scaling was out by a factor of 10 and had to mess a bit with the orientation. A bit of careful placing of the origin in relation to the joint orientation in my cad program before obj import meant I could use the meshes with some rotations, scaling, but no transforms necessary. Here is the final result which I’m really pleased with

ezgif-2-bd054cf924

now all I have to do is design the arms and body and programmatically put in some arm swing

2 Likes

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.