Add more zoom and pan navigation settings to MapView class

1911
4
11-18-2020 08:13 AM
Status: Open
Labels (1)
GILBERTNG1
New Contributor II

While in the process of upgrading an app from 4.13 to 4.17 JS API, we noticed that more animation/fade effects were added to 2D zooming and panning behavior, which is detrimental to UI performance when an app contains many layers. I would like to adjust this behavior in a simplistic manner, similar to how it was implemented in the 3.x API. For example, panDuration, panRate, zoomAnimationThrottled, zoomDuration, and zoomRate in the map object:

https://developers.arcgis.com/javascript/3/jsapi/esri.config-amd.html 

Here are navigation properties that are currently available in 4.x MapView class (see attached screenshot):
https://developers.arcgis.com/javascript/latest/api-reference/esri-views-navigation-Navigation.html

 

4 Comments
stelu
by

Did you find any solution in the mean time? All those animations make it difficult to compete against Leaflet or other closed source solutions for customers which use mobile devices with battery constraints or for customers who use virtual desktop infrastructure such like Citrix (where WebGL is usually done by CPU).

I'd be very happy for any suggestions on how to reduce CPU time use and in general making JSAPI 4.x somewhat fast.

GILBERTNG1

@stelu While we are in the progress of upgrading to version 4.20 of the JS API, I did notice that the LayerList widget is a big culprit for making navigations, such as mouse panning, a bit skippy. This was quite evident when having many layers on a map. The solution on our end was to call destroy() on the LayerList widget whenever it is not being used (corresponding Expand is closed), and initialize it when the expand is opened. 

BjornSvensson

@GILBERTNG1 - in regards to the LayerList issue you experienced, for version 4.24, we fixed a LayerList bug that might be the same you mention above.

See https://developers.arcgis.com/javascript/latest/4.24/#bug-fixes-and-enhancements 

GILBERTNG1

@BjornSvensson As an update to our original posting in this thread, we are noticing that on older iPad devices with 3-4GB or RAM and A12 or A13 CPU, we are getting web browser tab resets after anywhere from a few to several dozen pan & zoom operations on a complex web map. This only occurs on ArcGIS JS API 4.21 - Current, and is not an issue on legacy 3.X and <= 4.20 versions. In fact, we had to freeze one of our apps at 4.20 to keep mobile VPN users from having major issues. We were also able to replicate this issue on the new ArcGIS Map Viewer, to make sure that our custom JS is not the cause of these issues.

Also, we still desire to have something like panDuration, panRate, zoomAnimationThrottled, zoomDuration, and zoomRate setting available in 4.X MapView, to make our mapping apps more "snappy", especially on older devices.