Closed p-lr closed 6 years ago
@peterLaurence this is in 2.2.8, which is now live on bintray - maybe it's just me, but does this seem to affect performance for you at all? seems a bit more sticky/jumpy, but then again i'm not often on this machine and haven't run the test app for a while...
Thanks @peterLaurence & @moagrius for taking the time to look into this. I pulled this version into our app, and the blank tiles issue seems to be gone. However, I ran it on a Nexus 5X and also noticed the stickiness and jumpiness that @moagrius observed. @peterLaurence is this happening for you?
@moagrius @bb-juliogarcia This is strange because i dont have this issue on my side (even on emulator). Although i just made a fresh install on my old Nexus 5, and the first time i started the sample activity it was sticky/bumpy. Then i stopped the activity and restarted, and it was running smoothly.. strange. I will try to see if its due to my change, or if it only happens after a fresh install of the app (which could be the case since the java runtime can "learn" from previous executions).
EDIT : after some more tests, could not reproduce even on my old device. I haven't used my nexus 5 for a while, so maybe the cpu was not fully ready when i first tested the app.
Can you confirm on your side?
Same thing happened for me actually, the performance is fine now. Thanks for your work! @peterLaurence
Maybe it's worth noticing that the new android profiler in Android Studio 3.0.1 affects the performance of the app, which is not a big surprise since it goes much deeper into execution analysis.
interesting, and gtk
This fixes the missing tiles issue i could reproduce.
There is only one change : modifying the fast-fail test in
TileCanvasViewGroup.requestRender()
and removing all boilerplate code related tomLastRenderedDetailLevel
.The explanation of this change is, from the tests i run, when we have missing tiles after a quick zooming out, we can observe the following :
A high amount of request render are kicked in
TileCanvasViewGroup.requestRender()
which is based on a throttle logic. Those requests which usually pass through this enable the launch of new tile decoding with theTileRenderPoolExecutor
, in thebeginRenderTask
. So since no new task are sent to the executor, the rendering mechanism is broken. The addition of themTilesInCurrentViewport.size() > 0
in the fast-fail test enables the last request render to not fast-fail and trigger the missing render.As for the removing of the
mLastRenderedDetailLevel
, there are two reasons :