-
Notifications
You must be signed in to change notification settings - Fork 319
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
changed the default below layer for drawing route lines and manuever … #2878
Conversation
Codecov Report
@@ Coverage Diff @@
## master #2878 +/- ##
============================================
+ Coverage 35.43% 35.45% +0.01%
- Complexity 2103 2106 +3
============================================
Files 545 545
Lines 19554 19567 +13
Branches 1841 1844 +3
============================================
+ Hits 6929 6937 +8
- Misses 11799 11802 +3
- Partials 826 828 +2 |
@@ -1,6 +1,7 @@ | |||
package com.mapbox.navigation.ui.route; | |||
|
|||
class RouteConstants { | |||
static final String DEFAULT_ROUTE_LINE_LAYER_BELOW_ID = "road-label"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The Nav SDK cannot default to this layer id because a custom Map style might not have it. This would mean, that the route is most-likely end up being drawn on top of everything, including the puck.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What layer should be used?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The ideal fallback flow should be:
provided layer id -> LocationComponentConstants.SHADOW_LAYER
(if the layer exists) -> LocationComponentConstants.FOREGROUND_LAYER
(if the layer exists) -> null
SHADOW_LAYER is currently the default layer but the route line appears
above the street names because we never pass an alternative. So to address
the issue that was reported we should determine if our example apps should
be using passing a different layer in as a parameter.
…On Fri, May 1, 2020 at 9:14 AM Łukasz Paczos ***@***.***> wrote:
***@***.**** commented on this pull request.
------------------------------
In
libnavigation-ui/src/main/java/com/mapbox/navigation/ui/route/RouteConstants.java
<#2878 (comment)>
:
> @@ -1,6 +1,7 @@
package com.mapbox.navigation.ui.route;
class RouteConstants {
+ static final String DEFAULT_ROUTE_LINE_LAYER_BELOW_ID = "road-label";
The ideal fallback flow should be:
provided layer id -> LocationComponentConstants.SHADOW_LAYER (*if the
layer exists*) -> LocationComponentConstants.FOREGROUND_LAYER (*if the
layer exists*) -> null
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#2878 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AARFIWSG4GYB7CQ7G2MXQLDRPLYOTANCNFSM4MWXG4BQ>
.
|
That's right. Each implementation/example should provide the correct layer ID underneath which the route layer should be placed. This is heavily dependent on the used style, so we cannot effectively guess. The only convenience we can add is ensuring that, as a fallback, the route is at least placed below the location puck. |
Based on feedback the solution implemented in this PR is not the right solution to pursue so I"m closing this. |
Description
#2872 street names beneath route lines
bug
,feature
,new API(s)
,SEMVER
, etc.)Goal
The street names should appear above the route lines and turning arrows.
Implementation
Looking at the 0.42.4 source code the layer ID below which the route line was being drawn was mapbox-location however I don't see that layer when I list all of the layers in the style. I'm going to instead use the layer "road-label" as the default so that the street names will appear above the route line.
Screenshots or Gifs
Testing
Please describe the manual tests that you ran to verify your changes
SNAPSHOT
upstream dependencies if needed) through testapp/demo app and run all activities to avoid regressionsChecklist
CHANGELOG
including this PR