Skip to content

Commit

Permalink
simplify naki collisions
Browse files Browse the repository at this point in the history
  • Loading branch information
stibipet committed Feb 7, 2024
1 parent 32ee916 commit dd13094
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 16 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -327,21 +327,6 @@ limitations under the License.
{%- endmacro -%}
{# <!--}--> #}

{# visual_mesh_textured_with_collision_macro {--> #}
{%- macro visual_mesh_textured_with_collision_macro(name, mesh_file, mesh_scale, x, y, z, roll, pitch, yaw) -%}
{{ visual_mesh_textured_macro(name, mesh_file, mesh_scale, x, y, z, roll, pitch, yaw) }}
<collision name="{{ name }}_collision">
<pose>{{ x }} {{ y }} {{ z }} {{ roll }} {{ pitch }} {{ yaw }}</pose>
<geometry>
<mesh>
<uri>{{ mesh_file }}</uri>
<scale>{{ mesh_scale }}</scale>
</mesh>
</geometry>
</collision>
{%- endmacro -%}
{# <!--}--> #}

{# visual_colored_box_macro {--> #}
{%- macro visual_colored_box_macro(name, size_x, size_y, size_z, color, x, y, z, roll, pitch, yaw) -%}
<visual name="{{ name }}_visual">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@
<!--}-->

<!-- Legs {-->
{{ generic.visual_mesh_textured_with_collision_macro(
{{ generic.visual_mesh_textured_macro(
name = 'legs',
mesh_file = legs_mesh_file,
mesh_scale = mesh_scale,
Expand All @@ -151,6 +151,28 @@
pitch = 0,
yaw = 0)
}}
{{ generic.collision_cylinder_macro(
name = 'left_leg',
collision_length = 0.17,
collision_radius = 0.07,
x = 0,
y = -0.2,
z = -0.17,
roll = 0,
pitch = 0,
yaw = 0)
}}
{{ generic.collision_cylinder_macro(
name = 'right_leg',
collision_length = 0.17,
collision_radius = 0.07,
x = 0,
y = 0.2,
z = -0.17,
roll = 0,
pitch = 0,
yaw = 0)
}}
<!--}-->

<!-- Motors {-->
Expand Down

0 comments on commit dd13094

Please sign in to comment.