ROS2 and Gazebo: Adding roads to 3d world from a graph


Use: commercial.

Download link:
Note: This archive should be added to archive.

In the previous section, we learned how to create 2.5D landscapes from a topo map, turn them into a textured DAE file and use them in a Gazebo simulation.

However, topo maps have one huge "incompatibility" with the real world, which is called "roads". A road should be smooth, it should follow the landscepe, BUT it should be horizontal in the direction perpendicular to its orientation. In other words, while driving along the road, your car should tilt up or down, but not sideways:

When building roads, construction workers make them horizontal (in an "across" direction) so that a car doesn't slide off the road. The question is, how can we do it using topo map?

The answer is, we probably should not. Topo map is for smooth hills and valleys, while the road should be created in a way similar to what construction workers do: by removing part of the landscale and adding the road instead.

And of course, we should do it on a mesh, not at the topo map.

In this section, I am going to add this functionality to landscape generator ( utility). It will level up ground for the road, add road, stitch together the road and the rest of the landscape in a watertight (no holes) way and even add roads (darg bands) to the texture to make it look nicer.

Please note that unlike Map Editor, this is utility, not a user program. To use it you need to understand what it does and how, also you might change the parameters you use to alter the result.

(C), all rights reserved

Please read the disclaimer