-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Correct handling of intersections #14
Comments
|
Regarding 2.). indeed, I mean this line here, sorry: https://github.com/ad-freiburg/osm2rdf/blob/master/src/osm/GeometryHandler.cpp#L926 There, a relation I think we should:
|
…he R-Tree), this addresses point 1 from issue #14
* correct intersections for named area (explicitly check them against the R-Tree), this addresses point 1 from issue #14 * make intersect relations symmetric, add test for named area intersect * use the correct intersects-relation for symmetric relations
Point 1) from above is now fixed in master. I also made the intersect relations symmetric: if A intersects B, then B also intersects C. This is currently solved using the existing intersects_area and intersects_nonarea relations. I will add options for writing generic intersects and contains relation and the existing _nonarea and _area relations next. Note that since d970b22 there is now also the option |
I see two issues with the intersection relations as they are currently implemented:
The
intersects_area
relation is exactly equivalent to thecontains_area
relation (see https://github.com/ad-freiburg/osm2rdf/blob/master/src/osm/GeometryHandler.cpp#L453), which effectively means thatintersects_area
is only correct between areas in which one contains the other. To indeed handle all named area intersections, it would be necessary to again iterate over all named areas and check for intersections, again using the DAG for speedup (if A intersects B, than A intersects all geometries containing B in the DAG), exactly like it is currently done for the ways (starting at https://github.com/ad-freiburg/osm2rdf/blob/master/src/osm/GeometryHandler.cpp#L873).Intersect relations are not symmetric. In particular, even the
intersects_area
relations that are currently implemented (see above) are not symmetric (this fix should be trivial, though). However, I am not so sure about the summetry of intersections between different types. For example, if a way intersects an area, then aintersects_nonarea
relation is written between the area and the way, but the symmetric intersection should of course not be written, as the way intersects an area. It think, however, that anintersects_area
relation should then be written (in line https://github.com/ad-freiburg/osm2rdf/blob/master/src/osm/GeometryHandler.cpp#L926) between the way and the area.Any thoughts on this?
The text was updated successfully, but these errors were encountered: