-
Notifications
You must be signed in to change notification settings - Fork 118
Setting cameraMode cancels animation #544
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
In order to mix-up camera tracking with any other type of animation at the same time, you'll have to implement |
|
Clearing up the issue - currently, the developer is unable to use Mapbox's camera API to move, zoom or tilt the camera while the plugin's camera tracking is engaged because it will cancel those animations. Changing the camera position can be easily worked around by disengaging the tracking and working with However, there is no possibility to zoom or tilt the camera while tracking without disrupting the UX. Beside #550, another approach to solve this issue would be introducing additional methods to the plugin that would zoom in/out and tilt the camera using |
I know this is an old ticket, but I am again facing the same issue with the newest version of mapbox and the navigation sdk. On each navigation progress update I do a
@LukasPaczos how would disengaging look like? Or is this done differently in newer mapbox versions? |
Hey @stoefln, would you mind linking the nav examples you have in mind? Are the introduced We've also introduced the Generally, if you engage a tracking mode, the If above info doesn't help, could you provide a code example of your issue and cut a new ticket in the https://github.com/mapbox/mapbox-gl-native repo? Thanks! |
Thanks Lukas, |
When switching from overview to navigation mode in my app, I need to tilt the camera (3d perspective when driving). Additionally we need to set the cameraMode to a different one. The problem is that the tilt animation gets canceled when setting the cameraMode. I tried to do one after the other, using the animation callback, but its not a working solution either: when the user switches between modes quickly, the cameraMode cancels even the following animation. Blocking the user for around a second to quickly switch back to the first mode works, but it's not providing a good UX.
Is there an easier way to do this / am I missing something?
It seems to me that setting cameraMode is an asynchronous task, which takes some time. In this case there should be a callback available IMO.
A similar issue is that the animation gets cancelled on location update. How can this be avoided?
The text was updated successfully, but these errors were encountered: