Skip to content

[Bug] Using 3D Elevation in combination with tilt and panning results in some tiles not loadingΒ #2549

@plgagnon2

Description

@plgagnon2

Description

When enabling 3D terrain using a raster-dem source, tilting and panning the map causes vector tiles and 3D buildings to randomly pop in and out. Removing the terrain layer resolves the issue.

Expected Behavior

Tiles should load consistently during tilt and pan interactions.

Steps to Reproduce

  1. Set up a basic MapLibre map:

<Map mapStyle="test.json" />

  1. Use a style file based on MapTiler Streets v2 (create a free API key).

  2. In your test.json style file, add the following source:

"sources": {
  ...
  "terrain_dem": {
    "type": "raster-dem",
    "tiles": [
      "https://some_elevation_api/terrarium/zxy/{z}/{x}/{y}.png"
    ],
    "minzoom": 10,
    "maxzoom": 14,
    "encoding": "terrarium",
    "tileSize": 256,
    "attribution": "Terrarium"
  }
}
  1. In the root of the style JSON, enable terrain:
"terrain": {
  "source": "terrain_dem",
  "exaggeration": 1.0
}
elevation-glitch.mp4

Environment

  • Framework version: "react-map-gl": "^8.0.4",
  • Map library: "maplibre-gl": "^5.5.0",
  • Browser: Chrome 137.0.7151.69 (but also happens on any browser)
  • OS: macOS Sequoia 15.3.2 (but also happens on Windows/Linux)

Logs

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions