-
Notifications
You must be signed in to change notification settings - Fork 2.2k
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
Changing icon-data is slow (setData / Map Rotate / Bearing / Icon-Rotate) Version 1.3.0 and above. #8994
Comments
Are you able to reproduce this error in a minimal Javascript example that you could share (e.g. on JSBin)? I don't see anything obvious in the 1.3.0 changelog that might have changed this behavior and it's very hard to say what is happening without a reproducible case. |
This is a small test: The weird thing is: It only happens in the Android Webview in the application itself, not on my computer and not on the normal internet browser on my smartphone/tablet. Update: With the Google Internet Browser on Android Smartphone(Samsung S8) it also happens, but the delay is minimal. What can cause this, because with version 1.2.1 it doesnt happen. The small test does not contain map rotation/icon rotation/bearing/pitching etc, it will get worse. |
Update: Test with version 1.2.1 shows that there is no delay or minimal: Test with version (1.3.0 and above) 1.5.0 shows a delay on all devices, it is worse on a Android Webview but also shows on computer: you might need to refresh the page if the blue marker doesnt show up and errors are thrown in the console, it isnt a optimized test. |
@Stefano191 can you also please try the |
@mourner This indeed seems to fix my problem, when will this "fix" be released? And what are the issues with it? |
Thanks for confirming the fix! @Stefano191 at beta of the release is scheduled for Wednesday November 27th with the final release coming out on December 4th. I think the issue is #8998 but since that is being tracked separately I'll close this issue. |
I've recently switched from Mapbox gl js version 1.2.1 to 1.3.0 and later on to 1.5.0, i encountered a weird bug and i cant figure out why this happens:
So i got a Android Application with a Locationmanager which sends location updates every 750ms through a webview. Then i convert these coordinates to a latlng object and center the map and a icon arround these coordinates, i also calculate the bearing with Turf.js and rotate the map + the icon and set the map pitch to 60.
I update the icon-data with setData();
The normal(expected) behavior is shown below, the map + the icon centers around the black square which indicates the center of the map. (Version 1.2.1):
Click here
The weird behavior is shown below, the map centers correctly including the bearing/pitch but the icon isnt "following" the coordinates that are provided to him, it has a delay or something and after some time it catches up but still isnt centered(its a bit off), eventually it falls back again and i cant see it anymore and somehow freeze's and later catches up again. (Version 1.3.0 and above):
Click here
The delay or the "freezing" happens less if i dont pitch the map or rotate it, but still occurs. This also happens with a line with two points (A and B), but it is more accurate than the normal icon which isnt following most of the times or with a big delay.
Is there something changed in version 1.3.0 or above(all other versions have this same problem) or is this a bug, quz i cant seem to find out what the problem is.
Thanks for reading,
Stefano
The text was updated successfully, but these errors were encountered: