Skip to content
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

Enable night mode while in tunnels #559

Closed
ericrwolfe opened this issue Aug 29, 2017 · 4 comments
Closed

Enable night mode while in tunnels #559

ericrwolfe opened this issue Aug 29, 2017 · 4 comments
Assignees

Comments

@ericrwolfe
Copy link
Contributor

ericrwolfe commented Aug 29, 2017

We should be able to tell if a driver's in a tunnel and automatically enable dark mode.

However, this isn't something that's currently supported by the Directions API

cc @bsudekum @miccolis @v8c3

@daniel-j-h
Copy link

Upstream ticket for tunnels and other notifications:

Project-OSRM/osrm-backend#3028

I can remember talking to @1ec5 about tunnels when we added the classes way property and there was an argument against tunnels but I can't remember - @1ec5 could you chime in here?

@1ec5
Copy link
Contributor

1ec5 commented Aug 31, 2017

In this case, I don’t think we need an additional notification from OSRM. We already query the map vector tiles on each location update to get the current road’s name. #297 (which was closed but could easily be resurrected) refactors that code to give us rich information about the current road, including whether it’s in a tunnel or on a bridge.

@1ec5
Copy link
Contributor

1ec5 commented Jan 25, 2018

However, this isn't something that's currently supported by the Directions API

Project-OSRM/osrm-backend#4816 added a tunnel class. Once mapbox/mapbox-directions-swift#237 lands, we can switch to night mode as soon as the user crosses an intersection with the tunnel class and switch back to day mode as soon as they cross an intersection without the tunnel class.

@bsudekum
Copy link
Contributor

This shipped in #1127

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants