-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Add direction the user is facing to Nearby real-time position #1452
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
Comments
Hi, is anyone working on this? If not i would like to have a look at this. |
@Maeglad Feel free, it is now assigned to you! Please let us know about your progress regularly and ask questions if you need :-) |
Any updates on this @Maeglad ? :) |
I have done logic to calculate bearing from values of magnetic and accelerometer sensor, but right now I'm struggling a bit with rotating marker on map. Marker has no methods to rotate icon. From documentation of mapbox I learned that I should use SymbolLayer and iconRotate property of layer to rotate icon. I'll try it out and keep you updated how it is going. @misaochan |
Sounds like good progress, thanks for the update @Maeglad . :) |
@Maeglad Probably some network problem or problems of the server that provides the tiles. |
@nicolas-raoul I would like to work on this. I think we could reuse the code for #5433. |
@nicolas-raoul I have implemented the solution, but there seems to be one problem. Whenever I update the direction of the marker by using setRotation property of OSMDroid, the map recenters the user to the current location. So if a person is scrolling the map and simultaneously changing the direction of their phone, they are forcefully recentered in the map. Note: I have kept a sensitivity of 5 degrees, which means the dirn of the marker will be updated only when user turns their device by 5 degrees. Increasing this value will decrease the chances of marker getting updated while user is scrolling thro the map. Screencast: |
Interesting! Feel free to send a PR. :-) |
@ShashwatKedia, Can I help you with it! |
@ShashwatKedia I unassign for now, but if you are you still working on this, please let us know. Also, if you have any code even broken feel free to post a patch here. Thanks a lot. :-) |
AFAIK there was a discussion about this somewhere, but I think it was buried under a more general discussion.
Currently, our users see their real-time position as a dot. Which is great! But it would be much more useful if they could see what direction they were facing, similar to popular map apps. IMO this would make it easier for users to navigate using our Nearby map, without implementing full-on routing.
A brief look at how we can do that: https://stackoverflow.com/questions/14611493/point-arrow-to-direction-the-user-is-facing
The text was updated successfully, but these errors were encountered: