Invalid Mesh File error - "" is not a valid mesh file
When I import a STL model in Gazebo 7 Model Editor I receive the following error:
"" is not a valid mesh file. Please select another file for [visual]
The file has been exported from SolidWorks in ASCII format. I have tried with several models. One model is attached below, rename it from jpg to STL (because of upload requirements).C:\fakepath\table.jpg
Also no link appears in the Model tab
Any suggestions to why I receive this error and how to make the links work?
Setup:
- Gazebo 7.0 (ROS kinetic)
- Ubuntu 16.04
Edit 1:
I may have found a bug or two.
Even though the Uri for the STL file is in the text field in the Visual tab, then it gives me the error. If I browse to the STL in the exact same path, then it can now find it again.
Additionally, I noticed that when I go to the Link tab and enter a value for pose and hit Enter key, then it deletes both Uri paths in Visual and Collision.
Change x pose to 0.1 and hit Enter key
Error that the mesh file cannot be found
Uri to the STL is now empty
Edit 2:
Added small video with test in from Gazebo 9.0.0. The error appears after hitting the Enter key when setting the pose of the object.
Asked by robotlab on 2018-04-12 06:10:39 UTC
Answers
Can you try exporting from SolidWorks in other formats? The Gazebo model tutorial says:
Gazebo requires that mesh files be formatted as STL, Collada or OBJ, with Collada and OBJ being the preferred formats.
Asked by Raskkii on 2018-04-13 09:43:40 UTC
Comments
I will try with some other formats, but I noticed that my STL files do work, however, Gazebo randomly deletes the Uri when I change other values in the interface. See my original post for updated information.
Asked by robotlab on 2018-04-13 12:29:53 UTC
As seen in the comments above, the problem comes from a bug in the UI, which resets the Uri for the CAD model.
Asked by robotlab on 2018-04-16 12:19:39 UTC
Comments
Can you post you stl model file?
Asked by nkoenig on 2018-04-13 10:00:03 UTC
I have attached one of my STLs above (renamed to jpg because of upload requirements). I have added some additional information to my original post as I came across some bugs in the UI when editing the properties of a model.
Asked by robotlab on 2018-04-13 12:34:42 UTC
I've seen this issue before (the URI disappearing from the inspector). I just tried to reproduce it now on Gazebo 8 and couldn't, so I suspect it may have been solved in newer versions... You could try upgrading from 7
Asked by chapulina on 2018-04-13 14:13:21 UTC
I just tried with Gazebo 9.0.0 and experience the same, here is a small video https://goo.gl/9bULYj. I will also try with Gazebo 8. Btw, I am using the Gazebo versions from the ROS kinetic dist, not sure if this makes a difference.
Asked by robotlab on 2018-04-14 01:10:47 UTC
Ahh I know what's going on now, when you press enter, the
Reset
button is focused and it is triggered. There is a bug that resetting clears the URI. Would you mind ticketing an issue? https://bitbucket.org/osrf/gazebo/issues/Asked by chapulina on 2018-04-15 11:04:22 UTC
Ah ok, thanks a lot for figuring out what was going on :) Sure thing, will create an issue. Thanks again. Cheers
Asked by robotlab on 2018-04-15 12:54:52 UTC