Lane orientation

Issue #147 resolved
Agustin Alba Chicar created an issue

RNDF segments may have one or more lanes. Those lanes not necessarily have the same orientation. This causes some problems when partitioning the lanes as we don't travel go through the lane in the same geometric direction with incremental indexes. Further issues are raised when calculating the driveable bounds (see issue #143).

Some exploration has already been done. One of the tasks to be done is identifying the inverted lanes (based on something, for example the direction of the first lane). This is solved by calculating bounds of the complete map and choosing one of the corners of the bounding box as base point. Each lane will produce a momentum based on how these points are disposed on the map.

Also there was some previous exploration by rotating the waypoints of the RNDF once we detect that one lanes has another direction. This method seems to be simple and good enough but it derivates in a series of problems. When doing so, we loose the original interpolated tangent (we need to add 180° in phase) so junctions are broken as they connect two points with bad tangents and we need to do detection of the rotated waypoint.

The new proposed idea is once we identify the lane goes in another direction as the base reference, we can go through it in the inverse order so, that will remain the lane as it is but it will give use the ability to make the cuts where they should be. Connections between lanes will benefit from this approach as lanes will be created with the correct direction.

Parent issue #142

Comments (6)

  1. Agustin Alba Chicar reporter

    After some re-reading of the Maliput docs we found that lanes in a segment should describe a unique way of ordering from right to left them. Based on this, we could group RNDF lanes based on how they are set on the map (their direction) and then just create segments with RNDF lanes that go in the same direction.

    A preview of the current progress can be seen here:

    SegmentGrouping.png

    As the picture depicts, lanes with different directions are not OK. This is going to be solved once we include the code from #143.

  2. Agustin Alba Chicar reporter

    We added some extra waypoints at the beginning and at the end of the RNDF lanes to match the entire segment and avoid making cuts for the moment.

  3. Log in to comment