You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If the terrain dem tileset is sparse (tiles don't go up to the full maxzoom in all areas), terrain tiles can fail to load. Terrain only loads after a bunch of panning or zooming. Discovered through #11153
mapbox-gl-js version: main
browser: all
Steps to Trigger Behavior
add a sparse dem tile source
load the map in an area where the tiles don't go up to the max zoom level with a zoom greater than the max zoom that returns tiles.
Link to Demonstration
// internal
Expected Behavior
Terrain loads.
Actual Behavior
Terrain only loads after a bunch of panning.
If a tile 404s, we call sourceCache.update(...) to continue looking for a parent tile:
// If source is used for both terrain and hillshade, don't update it twice.
return;
}
If we pass the right flag to update(...), tiles will load successfully.
If we want to rely on recursive tile loading we need to review it carefully and add more tests. I don't think we've relied on this before, so I'm not confident there aren't other bugs.
The text was updated successfully, but these errors were encountered:
Setting the zoom and center to non-existing tiles once does not cause it, but doing it again after a couple of seconds does. The minimal project does not seem to fail 100% of the times, but in my test most do (the "idle" message is not printed to the console after the second center change).
To me it looks like the same issue, just less frequent, but let me know if you think I should open a new one.
I can confirm that the issue persists in the provided example. It seems that the map is in a loaded state even if we re-request parent tiles for missing children.
If the terrain dem tileset is sparse (tiles don't go up to the full maxzoom in all areas), terrain tiles can fail to load. Terrain only loads after a bunch of panning or zooming. Discovered through #11153
mapbox-gl-js version: main
browser: all
Steps to Trigger Behavior
Link to Demonstration
// internal
Expected Behavior
Terrain loads.
Actual Behavior
Terrain only loads after a bunch of panning.
If a tile 404s, we call
sourceCache.update(...)
to continue looking for a parent tile:mapbox-gl-js/src/source/source_cache.js
Lines 242 to 244 in f919053
But we skip the update for terrain tiles (as an optimization, not intended for this situtation):
mapbox-gl-js/src/source/source_cache.js
Lines 472 to 475 in f919053
If we pass the right flag to
update(...)
, tiles will load successfully.If we want to rely on recursive tile loading we need to review it carefully and add more tests. I don't think we've relied on this before, so I'm not confident there aren't other bugs.
The text was updated successfully, but these errors were encountered: