RobotLocomotion / models

Shareable model files (urdf/sdf + meshes, etc) for our robotics projects
25 stars 23 forks source link

Convert `iiwa7` and `iiwa14` .obj mesh files to glTF #36

Closed siddancha closed 3 months ago

siddancha commented 4 months ago

Related: https://github.com/RobotLocomotion/drake/pull/21079

Changes

Benefits

Visualization

Conversion process


This change is Reviewable

jwnimmer-tri commented 4 months ago

Thanks for this!

At the moment, we can't accept the draco files, even as as separate *.gltf files. We intended to use this repository to showcase the best practices for Drake's model files, and having duplicated *.gltf files (depending on the mesh compression) is not a best practice.

Our medium-term aim with draco meshes is to have them as "extentionsUsed" but not "extentionsRequired" in the same gltf file as the uncompressed meshes. Then consumers that know about draco will use them, but consumers that don't will fall back to the uncompressed mesh. A kind of "graceful degradation" so that we don't need (for example) separately forked SDFormat files for the two mesh styles.

So I'll ask that for this first PR, please just keep the normal uncompressed meshes and git rm the draco ones for now. Once we have more Drake capabilities and tooling related to draco meshes ready, we can start using draco here.

siddancha commented 4 months ago

Makes sense @jwnimmer-tri . Removed all draco-related files.

siddancha commented 4 months ago

@jwnimmer-tri I want to add that I tweaked some material parameters in the glTF files. For one, the original .obj files don't contain any material/color information. I copied the RGB values provided in RobotLocomotion/drake's iiwa_description URDF files. Since material properties in glTF files are more expressive (e.g. metallicFactor, roughnessFactor), I picked sensible values guided by how aesthetic the iiwas looked in meshcat.