prochitecture / blosm

GNU General Public License v3.0
11 stars 3 forks source link

A change in the data structure for intersections #101

Closed vvoovv closed 5 months ago

vvoovv commented 5 months ago

Suppose a street enters an intersection:

street.succ is intersection

I want to get a street on the left from street and a street on the right from street, that are also attached to the intersection

streetL.succ is intersection or streetL.pred is intersection
streetR.succ is intersection or streetR.pred is intersection

I suggest setting street.succ or street.pred to an instance of the class IntConnector. Then it will be quite straightforward to get streetL or streetR:

streetL = street.succ.pred.item
streetR = street.succ.succ.item
polarkernel commented 5 months ago

I suggest setting street.succ or street.pred to an instance of the class IntConnector.

Implemented and committed.

Note that the Section instances remain untrimmed at the connectors. The intersection area is still computed, although this will eventually be done by GNs. I will clean up the code once we are in a more stable state.

vvoovv commented 5 months ago

Thanks.

Anyway, overlapping intersections will require a special processing in the code.