Gazebo | Ignition | Community
Ask Your Question
0

how to convert collada .dae file to gazebo model

asked 2016-06-03 06:47:12 -0500

Rajnunes gravatar image

i have a .dae collada file .How eaxctly do i convert it to a gazebo model... gazebo 2.2

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
1

answered 2016-06-03 07:00:12 -0500

Brosseau.F gravatar image

updated 2016-06-03 08:41:20 -0500

You can import a collada file in a link (http://sdformat.org/spec?ver=1.6&elem=geometry). Look at the mesh tag and uri tag.

If all your robot is the collada, you can probably open it in Blender and export each part of the robot in a collada file that you will use in a sdf link.

Update :

Example of a building that I have :

There is my model :

<?xml version='1.0'?>
<sdf version='1.5'>
  <model name='building_curve'>
    <static>true</static>
    <link name="curve1">
      <visual name="visual">
            <geometry>
                <mesh>
                    <uri>model://building/model/curve/materials/meshes/curve_building_1.dae</uri>
                </mesh>
            </geometry>
        </visual>
        <collision name="collision">
            <geometry>
                <mesh>
                    <uri>model://building/model/curve/materials/meshes/curve_building_1.dae</uri>
                </mesh>
            </geometry>
        </collision>
    </link>
  </model>
</sdf>

There is my world file :

<?xml version="1.0"?>
<sdf version="1.4">
  <world name="default">
    <include>
      <uri>model://ground_plane</uri>
    </include>
    <include>
      <uri>model://building/model/curve</uri>
      <pose>15.64 -12.89759 0 0 0 0</pose>
    </include>
    <include>
      <uri>model://sun</uri>
    </include>
  </world>
</sdf>
edit flag offensive delete link more

Comments

Its actually a building and i dont really know how to convert it to a gazebo model.. @Brosseau.F

Rajnunes gravatar imageRajnunes ( 2016-06-03 07:43:58 -0500 )edit

See my updated answer. I had made an example.

Brosseau.F gravatar imageBrosseau.F ( 2016-06-03 08:43:20 -0500 )edit
Login/Signup to Answer

Question Tools

1 follower

Stats

Asked: 2016-06-03 06:47:12 -0500

Seen: 7,215 times

Last updated: Jun 03 '16