Robotics StackExchange | Archived questions

Error openning model with .dae meshes : what(): bad lexical cast: source type value could not be interpreted as target

I am trying to add a model I created using a .dae file as meshe in gazebo, but I am getting the following error:

terminate called after throwing an instance of 'boost::exception_detail::clone_impl<boost::exception_detail::error_info_injector<boost::bad_lexical_cast> >'
  what():  bad lexical cast: source type value could not be interpreted as target

The model.sdf is:

<?xml version="1.0" ?>
<sdf version="1.5">
  <model name="Supermarket">

    <link name="link">
      <collision name="collision">
        <geometry>
          <mesh>
            <uri>model://Supermarket/meshes/gicshelf.dae</uri>
          </mesh>
        </geometry>
      </collision>

      <visual name="visual">
        <geometry>
          <mesh>
            <uri>model://Supermarket/meshes/gicshelf.dae</uri>
          </mesh>
        </geometry>
      </visual>

    </link>

  </model>
</sdf>

I was using a different .dae before and it was working just fine, so I guess the problem is in the new .dae file, but I have no idea what to change to make it work. I am able to open this same .dae file in a online .dae viewer.

Asked by rezenders on 2020-12-17 07:05:38 UTC

Comments

Is the mesh using a texture? If so, double-check that the path to the texture in the .dae can be found by Gazebo.

Asked by Carlos Agüero on 2020-12-18 14:10:27 UTC

maybe a locale issue?

Asked by iche033 on 2020-12-18 14:20:22 UTC

Answers