-
-
Notifications
You must be signed in to change notification settings - Fork 5.8k
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
Excess tile loading in animated setView #4109
Comments
@hyperknot which version, latest master or released beta2? This should be (at least partly) fixed by e2fbe19 |
@yohanboniface I was testing beta2, I've just tested with e2fbe19 and so far it seems to be using equal amount of requests to 0.7! |
The only scenario where I see excess (around double) tile usage is when jumping to a remote point via |
Good news :)
Just to appreciate whether it's a blocker for the 1.0 release, is this behaviour also with 0.7, or specific to 1.0? |
I tested it and setView animate behaviour is the same as with 0.7. Should I close this one and open an issue for setView animate tile usage? |
Just rename this one :) |
I'm working on a test case, but it's really hard to replicate, somehow it's not happening in a minimal case. |
Did a test case here (I get 31 vs. 9 requests, but it's random): After reading Leaflet's code, I believe this is not a bug, this is what animate: true is supposed to do. Actually, Leaflet/src/map/anim/Map.PanAnimation.js Line 96 in 3fd2d5c
and Leaflet/src/map/anim/Map.PanAnimation.js Line 49 in 3fd2d5c
The best/simplest solution would be to allow the user to set the pan animation threshold like |
@hyperknot I'm guessing #4193 might have fixed this already. Can you please check? |
@IvanSanchez this is still happening. Animated version gets 15-26 tiles, non-animated 9 always. What do you think is the best solution here? Calculating average speed during panAnimation and disabling animation if the speed is above a given threshold? |
At a given window resolution, a fully loaded map takes 20 requests. Changing the map takes 20 new requests. Zooming out takes 20 requests. Yet, zooming in takes 48 or 56 requests.
Same with detectRetina: switching basemap, zooming out, takes 64 requests. Yet zooming in takes 192 or 208 requests.
This is not related to retina / detectRetina, it happens with non-retina maps as well.
The text was updated successfully, but these errors were encountered: