Select to view content in your preferred language

WebTiledLayer tile loading indication

451
3
02-10-2024 08:47 AM
dev4567
Emerging Contributor

Is there a way to indicate concrete tile is being loaded? Some tiles could be quite massive and users with poort network connection should know the tile is actually loaded and not just empty or "stuck"

Tags (1)
0 Kudos
3 Replies
PuneetPrakash
Esri Contributor

You can set how a tile request that returns 'No Data' is resampled by setting noDataTileBehavior  property on the WebTiledLayer,
This lets you choose what to display where the tile should have been displayed,


NoDataTileBehavior.UpSample - Resample the pixels from a lower level of detail tile.

NoDataTileBehavior.Blank - The 'NoData' pixels will show the raster picture as being blank (or disappearing).

NoDataTileBehavior.Show - This will show the raster picture with the text 'No Data' stamped over it once you pass the lowest level-of-detail scale.


https://developers.arcgis.com/kotlin/api-reference/arcgis-maps-kotlin/com.arcgismaps.mapping.layers/...

0 Kudos
dev4567
Emerging Contributor

unfortunately, this doesn't help when the map is being loaded the first time

0 Kudos
PuneetPrakash
Esri Contributor

You can try using the layerViewStateChanged  callback on the GeoView that gives you the LayerViewStatus on individual layers in the MapView. When the tiles in the WebTiledLayer are not successfully loaded you will get the Warning LayerViewStatus. If you get that then the LayerViewState.error property will provide more details about the specific problem which was encountered. 

0 Kudos