-
Notifications
You must be signed in to change notification settings - Fork 11
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
Map readability issue due to label collisions between layers #64
Comments
I've done a bit of research and found that while the symbol collision detection system doesn't support arbitrary geometry, it's possible to work around this by adding invisible symbols to the map that approximate the shape of the geometry. This might sound like a hack, but given that the system only supports rectangles and circles, this is exactly how the original implementer proposes supporting arbitrary geometry:
|
Hi @varette |
Nothing to worry about, I'm just thinking about ways to improve the map out of personal interest, since I'd love to see indoor maps become a standard feature in OSM apps. You're right that my solution wouldn't help, so I've had a different idea. We can use a filter layer and the "within" statement to filter out POIs within an arbitrary feature collection's geometry. So if we build a polygon that bounds the indoor geometry plus some buffer, then we can use it to filter out most of the POIs which are overlapping the indoor layer. I've implement a prototype of this (source), and it seems like it could work. It's a rough experiment, there's probably a much more efficient way to build a bounding polygon. Right now I build the filtering polygons by running the level's geometry through turf's "buffer", "simplify, then "union". |
Hello! Although this project is definitely the best way to visualize OSM indoor map data, I find that for map data with odd shapes or gaps in them, the display can get quite cluttered by labels from base layers which overlap with the indoor geometry. Although those labels are underneath the indoor map, and they don't collide with labels on the indoor symbol layer, it still adds noise that makes comprehending the map more difficult. Some examples:
Obviously maplibre's label placement only takes other labels into account and not geometry, which means that any part of a room that is not covered by a symbol is at risk of having this clutter at its edges.
I'm wondering if there would be a way to make the labels of a specific layer avoid the geometry of another layer.
The text was updated successfully, but these errors were encountered: