GeoLeaf Core API - v3.19.0
    Preparing search index...

    Function deactivateTerrain

    • Deactivates 3D terrain rendering — the terrain of the "basemap" activation mode.

      • Calls map.setTerrain(null) to detach the terrain.
      • Defers removeSource("terrain-dem") via map.once("render") to avoid MapLibre errors when the source is still referenced by the render pipeline. The removal is given up when the source has been claimed again by then, and a removal the engine refuses — a layer still reads the source — is logged as such, the source left in place.
      • Resets pitch and bearing to 0 via map.easeTo().
      • Stops listening to the map: nothing puts this terrain back afterwards.

      Parameters

      • map: NativeMap | null

        The native maplibregl.Map instance.

      Returns void