maplibre-gl-js icon indicating copy to clipboard operation
maplibre-gl-js copied to clipboard

Raster tiles are much lower detail when terrain is enabled

Open olsen232 opened this issue 2 months ago • 12 comments

(This may not be a bug - if that's the case, I am just looking for info about how to control this behaviour).

Adding terrain to a map viewer causes it to load raster tiles at lower zoom, that is, load the lower detail rasters with a lower "z" value. Also, the zoom drops away much quicker when terrain is enabled, so that one end of the screen is noticeably lower detail than the other even for a reasonably small camera pitch, and worse for extreme pitches. Maps without terrain, by contrast, do a good job of maintaining the illusion that all tiles change zoom at once.

maplibre-gl-js version: 4.1.2

browser: Brave

Steps to Trigger Behavior

  1. Set up a map with raster tiles. Turn on map.showTileBoundaries
  2. Compare it with the same map but also with 3d terrain enabled.
  3. Observe different tile zoom levels in each case.

Link to Demonstration

Map with terrain disabled: https://jsbin.com/mesowukici/1/edit?html,output Screenshot 2024-04-12 at 2 19 50 PM

Identical map with terrain enabled: https://jsbin.com/rigisawuze/1/edit?html,output Screenshot 2024-04-12 at 2 20 01 PM

Expected Behavior

Adding terrain shouldn't affect raster tile zoom - maybe? This may be by design for performance reasons. If so, do you know if it can be tweaked?

Actual Behavior

Adding terrain has a large and obvious impact on raster tile zoom.

olsen232 avatar Apr 12 '24 04:04 olsen232