Ask Your Question


asked 2012-07-26 17:48:41 -0500

Is there any advantages or disadvantages of using one over the other in a urdf file?

i.e. Collision computation time? rendering? etc...

edit retag flag offensive close merge delete

2 Answers

Sort by ยป oldest newest most voted

answered 2012-07-27 03:27:50 -0500

Adolfo Rodriguez T gravatar image

The STL file format comes from the CAM and rapid prototyping world, and thus encodes geometry information only, as triangle meshes. STL includes no material specification whatsoever.

The Collada format, on the other hand was intended for exchanging digital assets, and can encode not only 3D geometry, but also physics, kinematics, animations/morphing, shaders, manages level-of-detail, and more. For the specific case of modeling single rigid bodies, Collada is a good choice if you want to specify not only the geometry, but custom material properties such as texture maps (instead of a single solid color), normal maps (for adding more detail without adding more polygons), specularity maps (to specify reflectivity properties [1]), and so on.

So, if what you have for a visualization geometry is a single-colored triangle mesh, you could go for binary STL, as the equivalent (non-binary) Collada file size might be larger (by ~50% in my tests). If you can generate one or more of the above mentioned maps (texture, normal, specular), I'd recommend to go with Collada. For a collision geometry I use binary STLs because of the reduced file size.

Computation time should not be affected by the file format (except for the negligible asset import step, which is done only once), but by the file contents (eg. number of polygons). That goes for both rendering and collision detection.

[1] The current Gazebo/rviz lighting models do not seem to have specularity effects enabled.

edit flag offensive delete link more

answered 2012-07-27 02:22:13 -0500

dornhege gravatar image

AFAIK dae allows colors, STL not.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower


Asked: 2012-07-26 17:48:41 -0500

Seen: 6,308 times

Last updated: Jul 27 '12