-
Notifications
You must be signed in to change notification settings - Fork 2.2k
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
Add the ability to not draw text that is illegible #9569
Comments
@jwoodwardtfx have you considered setting |
While I agree that would slightly improves legibility, it still doesn't fix the problem as labels far from the camera as still so small as to be unreadable. Also, I don't really want to loose the labels being aligned to the road (as for roads near the camera this looks sensible). The problem is to do with the distance from the camera, and having no way to make a styling decision based on this. Not rendering text based on it's size would be a (fairly?) simple hack to workaround my need, but there may be a more general case here...? |
#9219 should fix it |
Thanks, #9219 certainly looks interesting but I don't think it will fix the issue. It looks like it'll improve the placement of the labels (especially at higher pitches), but the problem I have is not the placement of the labels but that the labels are drawn at all when the text is so small as to not be legible. It's more about adjusting the level of detail on the map, and reducing it further from the camera. It something a typically SatNav would do (i.e. more detail closer to the camera where it is useful, but less detail further away). It's probably more like #8975, but a little less crude than applying to just "distant tiles", i.e. to set the style within a tile according to distance from the camera. This would probably be achievable by a filter on the style that takes a distance to camera as an input? |
@jwoodwardtfx , do you mind trying out the beta https://www.npmjs.com/package/mapbox-gl/v/1.10.0-beta.1 and see whether the combination of what @ansis proposed with the new work introduced by #9219 increases the readability? |
I've given it a go, and not a huge difference. The problem isn't the placement of the label or the level of detail in tiles far-away when the camera has a really low pitch. The problem is the drawing of labels for nearby tiles that are far from the camera. The following screenshot is from v1.10.0-beta.1: The labels for the roads around the "Withington Bowling Club" are not readable and clutter the map (and take up unnecessary performance). It's labels like these that I'd like to be able to not have drawn. Those "near" the camera are fine (and I'd like to keep these aligned to the roads they are on). I think something like a filter based on "distance to the camera" in the style for each layer would work? Thanks. |
How do I get the "needs information" tag off this? I think plenty has been provided, including a description of the issue and screenshots. Thanks |
We have an application where we have fairly detailed maps and the camera displays in 3D (with a pitch of 60 degrees).
Some text becomes illegible when drawn far from the camera, especially road names in built-up dense residential areas that are styled with a "symbol-placement" of "line" .
A few examples are shown in the red ellipses in the screenshot below:
Is it possible to have a flag that would allow text that would be rendered illegibly (or below a certain size) to not actually be drawn (this would improve render performance and declutter the map for areas further from the camera)?
The root problem is that at the given zoom level we only want the text rendered when close to the camera.
Thanks
The text was updated successfully, but these errors were encountered: