Skip to content

Route preview example - #111

Merged
vadzim-vys merged 13 commits into
mainfrom
vv-routes-preview
Sep 8, 2022
Merged

Route preview example#111
vadzim-vys merged 13 commits into
mainfrom
vv-routes-preview

Conversation

@vadzim-vys

@vadzim-vys vadzim-vys commented Aug 4, 2022

Copy link
Copy Markdown
Contributor

This example demonstrates how to preview a route using current capabilities of the SDK

route-preview-example.mp4

@vadzim-vys
vadzim-vys marked this pull request as ready for review August 4, 2022 15:57
@vadzim-vys
vadzim-vys requested a review from a team as a code owner August 4, 2022 15:57
@RingerJK

RingerJK commented Aug 8, 2022

Copy link
Copy Markdown
Contributor

@VysotskiVadim could you add video of gif?

@vadzim-vys

Copy link
Copy Markdown
Contributor Author

@VysotskiVadim could you add video of gif?

added

@abhishek1508

Copy link
Copy Markdown
Contributor

Let's wait before we merge this example. It basically recommends user what we do on 1Tap, Drop-In etc. i.e. request a route using Mapbox navigation and apply to route line. Later set it to mapboxNavigation.

I think we should be aligned here if this is what we want to recommend before committing to it.

@vadzim-vys

Copy link
Copy Markdown
Contributor Author

Let's wait before we merge this example. It basically recommends user what we do on 1Tap, Drop-In etc. i.e. request a route using Mapbox navigation and apply to route line. Later set it to mapboxNavigation.

I think we should be aligned here if this is what we want to recommend before committing to it.

I think it's the best what we can do with current version of the SDK. If we, and I believe we will, add support of preview to core, I will update the example to represent the best way a user can implement a route preview using the Navigation SDK. What do you think?

Comment thread app/src/main/java/com/mapbox/navigation/examples/preview/PreviewActivity.kt Outdated
Comment thread app/src/main/java/com/mapbox/navigation/examples/preview/PreviewActivity.kt Outdated
Comment thread app/src/main/java/com/mapbox/navigation/examples/preview/PreviewActivity.kt Outdated
@vadzim-vys vadzim-vys self-assigned this Sep 1, 2022
@RingerJK

RingerJK commented Sep 1, 2022

Copy link
Copy Markdown
Contributor

I suppose it's possible to preview a route during Active Guidance session, right? Wdyt if we add the sample as well at the same screen?

@vadzim-vys

Copy link
Copy Markdown
Contributor Author

I suppose it's possible to preview a route during Active Guidance session, right? Wdyt if we add the sample as well at the same screen?

This is a valid scenario. But it has the lower priority in comparison to the flow Free drive -> Preview -> Active Guidance. The case you mention will be addressed later.

Comment thread app/src/main/java/com/mapbox/navigation/examples/preview/PreviewActivity.kt Outdated
.coordinatesList(listOf(originPoint, destination))
// provide the bearing for the origin of the request to ensure
// that the returned route faces in the direction of the current user movement
.bearingsList(

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we need bearings, layers and alternatives here? Do they have anything to do with route preview (well, maybe just the alternatives do)?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we need bearings, layers

I think all route requests should be with bearing and layers. I don't want to create an impression that it isn't necessary.

and alternatives here?

Yes, preview should support alternatives.

@abhishek1508 abhishek1508 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@vadzim-vys
vadzim-vys merged commit 6f66ce6 into main Sep 8, 2022
@vadzim-vys
vadzim-vys deleted the vv-routes-preview branch September 8, 2022 11:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants