Gazebo | Ignition | Community
Ask Your Question

Revision history [back]

You could use the model editor to create it graphically.

Or you could write SDF directly. Something like this:

<model name="box">
  <pose>0 0 0.5 0 0 0</pose>
  <link name="link">
    <collision name="collision">
      <geometry>
        <box>
          <size>1 1 1</size>
        </box>
      </geometry>
    </collision>
    <visual name="visual">
      <geometry>
        <box>
          <size>1 1 1</size>
        </box>
      </geometry>
      <material>
        <script>Gazebo/Red</script> <!-- Green / Blue -->
      </material>
    </visual>
  </link>
</model>

If you're new to making Gazebo models, this tutorial has a nice introduction.