Skip to content

Commit

Permalink
Update atlas model to have textures.
Browse files Browse the repository at this point in the history
The conversion path was a bit convoluted:
  - These came from the original MIT DRC repo => openhumanoids/oh-distro
(the same source as the existing models in this directory), with some
elbowgrease in converting dae to obj+mtl, then obj2gltf -s.
  - .jpg was converted to .png
  - Much of the geometry was manually tweaked to improve the normals in Blender.
  - One of the URDFs removed convex hulls as visuals for the corresponding glTFs (where available).

Models and scripts can be found in:
RussTedrake/oh-distro@76f8c4b

Co-Authored-By: Sean Curtis <sean.curtis@tri.global>
  • Loading branch information
RussTedrake and SeanCurtis-TRI authored Jan 9, 2025
1 parent 78cad6a commit 43a7e91
Show file tree
Hide file tree
Showing 59 changed files with 2,836 additions and 1,958 deletions.
15 changes: 5 additions & 10 deletions atlas/atlas_convex_hull.urdf
Original file line number Diff line number Diff line change
Expand Up @@ -1008,16 +1008,14 @@
<visual>
<origin rpy="0 0 0" xyz="0 0 0"/>
<geometry>
<mesh filename="package://drake_models/atlas/meshes/head_chull.obj"/>
<mesh filename="package://drake_models/atlas/meshes/head.gltf"/>
</geometry>
<material name="">
<color rgba="0.9098 0.44314 0.031373 1"/>
</material>
</visual>
<collision>
<origin rpy="0 0 0" xyz="0 0 0"/>
<geometry>
<mesh filename="package://drake_models/atlas/meshes/head_chull.obj"/>
<drake:declare_convex/>
</geometry>
</collision>
</link>
Expand Down Expand Up @@ -1121,11 +1119,8 @@
<visual>
<origin rpy="-0.314 0 0" xyz="0.045 -0.0261018277 -0.08342369"/>
<geometry>
<mesh filename="package://drake_models/atlas/meshes/head_camera_chull.obj"/>
<mesh filename="package://drake_models/atlas/meshes/head_camera.gltf"/>
</geometry>
<material name="">
<color rgba="0.72941 0.35686 0.023529 1"/>
</material>
</visual>
<collision>
<origin rpy="-0.314 0 0" xyz="0.045 -0.0261018277 -0.08342369"/>
Expand Down Expand Up @@ -1549,7 +1544,7 @@
<visual>
<origin rpy="-1.57079 -1.57079 0" xyz="0 0.1725 0"/>
<geometry>
<mesh filename="package://drake_models/atlas/meshes/GRIPPER_OPEN_chull.obj" scale="1 1 1"/>
<mesh filename="package://drake_models/atlas/meshes/GRIPPER_OPEN_chull.gltf" scale="1 1 1"/>
</geometry>
</visual>
<collision>
Expand All @@ -1567,7 +1562,7 @@
<visual>
<origin rpy="-1.57079 -1.57079 0" xyz="0 0.1725 0"/>
<geometry>
<mesh filename="package://drake_models/atlas/meshes/GRIPPER_OPEN_chull.obj" scale="1 1 1"/>
<mesh filename="package://drake_models/atlas/meshes/GRIPPER_OPEN_chull.gltf" scale="1 1 1"/>
</geometry>
</visual>
<collision>
Expand Down
Binary file added atlas/meshes/GRIPPER_OPEN_chull.bin
Binary file not shown.
91 changes: 91 additions & 0 deletions atlas/meshes/GRIPPER_OPEN_chull.gltf
Original file line number Diff line number Diff line change
@@ -0,0 +1,91 @@
{
"asset":{
"generator":"Khronos glTF Blender I/O v4.3.47",
"version":"2.0"
},
"scene":0,
"scenes":[
{
"name":"Scene",
"nodes":[
0
]
}
],
"nodes":[
{
"mesh":0,
"name":"GRIPPER_OPEN_chull"
}
],
"meshes":[
{
"name":"GRIPPER_OPEN_chull",
"primitives":[
{
"attributes":{
"POSITION":0,
"NORMAL":1
},
"indices":2
}
]
}
],
"accessors":[
{
"bufferView":0,
"componentType":5126,
"count":60,
"max":[
0.12167400121688843,
0.059567999094724655,
0.0637039989233017
],
"min":[
-0.11667700111865997,
-0.15751999616622925,
-0.06420499831438065
],
"type":"VEC3"
},
{
"bufferView":1,
"componentType":5126,
"count":60,
"type":"VEC3"
},
{
"bufferView":2,
"componentType":5123,
"count":60,
"type":"SCALAR"
}
],
"bufferViews":[
{
"buffer":0,
"byteLength":720,
"byteOffset":0,
"target":34962
},
{
"buffer":0,
"byteLength":720,
"byteOffset":720,
"target":34962
},
{
"buffer":0,
"byteLength":120,
"byteOffset":1440,
"target":34963
}
],
"buffers":[
{
"byteLength":1560,
"uri":"GRIPPER_OPEN_chull.bin"
}
]
}
Binary file added atlas/meshes/drc_torso_head_diffuse.ktx2
Binary file not shown.
Binary file added atlas/meshes/drc_torso_head_diffuse.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified atlas/meshes/head.bin
Binary file not shown.
214 changes: 110 additions & 104 deletions atlas/meshes/head.gltf
Original file line number Diff line number Diff line change
@@ -1,142 +1,148 @@
{
"asset":{
"generator":"Khronos glTF Blender I/O v4.3.47",
"version":"2.0"
},
"scene":0,
"scenes":[
{
"name":"Scene",
"nodes":[
0
]
}
],
"nodes":[
{
"mesh":0,
"name":"Node"
}
],
"materials":[
{
"name":"drc_torso_head_diffuse",
"pbrMetallicRoughness":{
"baseColorTexture":{
"index":0
},
"metallicFactor":0,
"roughnessFactor":0.9980000257492065
}
}
],
"meshes":[
{
"name":"Node-Mesh",
"primitives":[
{
"attributes":{
"POSITION":0,
"NORMAL":1,
"TEXCOORD_0":2
},
"indices":3,
"material":0
}
]
}
],
"textures":[
{
"sampler":0,
"source":0,
"extensions":{
"KHR_texture_basisu":{
"source":1
}
}
}
],
"images":[
{
"mimeType":"image/png",
"name":"drc_torso_head_diffuse",
"uri":"drc_torso_head_diffuse.png"
},
{
"mimeType":"image/ktx2",
"uri":"drc_torso_head_diffuse.ktx2"
}
],
"accessors":[
{
"name":"Node-Mesh_0_positions",
"bufferView":0,
"componentType":5126,
"count":1737,
"min":[
-0.14794300496578217,
-0.03178200125694275,
-0.11721300333738327
],
"count":973,
"max":[
0.019957000389695168,
0.1447180062532425,
0.11778700351715088
0.052000001072883606,
0.14429999887943268,
0.14980000257492065
],
"type":"VEC3",
"bufferView":0,
"byteOffset":0
},
{
"name":"Node-Mesh_0_normals",
"componentType":5126,
"count":1737,
"min":[
-1,
-1,
-1
],
"max":[
1,
1,
1
-0.11590000241994858,
-0.03220000118017197,
-0.0851999968290329
],
"type":"VEC3",
"type":"VEC3"
},
{
"bufferView":1,
"byteOffset":0
"componentType":5126,
"count":973,
"type":"VEC3"
},
{
"name":"Node-Mesh_0_indices",
"componentType":5123,
"count":3297,
"min":[
0
],
"max":[
1736
],
"type":"SCALAR",
"bufferView":2,
"byteOffset":0
}
],
"asset":{
"generator":"obj2gltf",
"version":"2.0"
},
"buffers":[
"componentType":5126,
"count":973,
"type":"VEC2"
},
{
"name":"head",
"byteLength":48284,
"uri":"head.bin"
"bufferView":3,
"componentType":5123,
"count":2805,
"type":"SCALAR"
}
],
"bufferViews":[
{
"name":"bufferView_0",
"buffer":0,
"byteLength":20844,
"byteLength":11676,
"byteOffset":0,
"byteStride":12,
"target":34962
},
{
"name":"bufferView_1",
"buffer":0,
"byteLength":20844,
"byteOffset":20844,
"byteStride":12,
"byteLength":11676,
"byteOffset":11676,
"target":34962
},
{
"name":"bufferView_2",
"buffer":0,
"byteLength":6596,
"byteOffset":41688,
"target":34963
}
],
"materials":[
"byteLength":7784,
"byteOffset":23352,
"target":34962
},
{
"name":"default",
"pbrMetallicRoughness":{
"baseColorFactor":[
0.5,
0.5,
0.5,
1
],
"metallicFactor":0,
"roughnessFactor":1
},
"emissiveFactor":[
0,
0,
0
],
"alphaMode":"OPAQUE",
"doubleSided":false
"buffer":0,
"byteLength":5610,
"byteOffset":31136,
"target":34963
}
],
"meshes":[
"samplers":[
{
"name":"Node-Mesh",
"primitives":[
{
"attributes":{
"POSITION":0,
"NORMAL":1
},
"indices":2,
"material":0,
"mode":4
}
]
"magFilter":9729,
"minFilter":9987
}
],
"nodes":[
"buffers":[
{
"name":"Node",
"mesh":0
"byteLength":36748,
"uri":"head.bin"
}
],
"scene":0,
"scenes":[
{
"nodes":[
0
]
}
"extensionsUsed":[
"KHR_texture_basisu"
]
}
Binary file modified atlas/meshes/head_camera.bin
Binary file not shown.
Loading

0 comments on commit 43a7e91

Please sign in to comment.