Type alias TMapViewOptions

TMapViewOptions: {
    alpha?: boolean;
    antialias?: TAntialiasConfiguration["antialias"];
    antialiasQuality?: TAntialiasConfiguration["antialiasQuality"];
    aoEnabled?: TAOConfiguration["aoEnabled"];
    aoQuality?: TAOConfiguration["aoQuality"];
    aoResolution?: TAOConfiguration["aoResolution"];
    backgroundAlpha?: number;
    backgroundColor?: string;
    debug?: boolean;
    disableHover?: boolean;
    disableZoomOnMapSizeChange?: boolean;
    dynamicFocus?: {
        baseMap?: MappedinMap;
        buildingFullyVisibleZoomLevel?: number;
        indoorsFullyVisibleZoomLevel?: number;
        keepLayersActiveOnBaseMap?: string[];
        preloadDefaultMaps?: boolean;
        setMapAtZoomLevel?: number;
    };
    dynamicPerformance?: boolean;
    firstMap?: MappedinMap | string;
    layerGroups?: {
        layers: string[];
        opacityInterpolation?: {
            opacity: number;
            zoomLevel: number;
        }[] | {
            inputZoomLevel: number[];
            outputOpacity: number[];
        };
        visible?: boolean;
    }[];
    loadOptions?: {
        async?: boolean;
        mapRenderStrategy?: MAP_RENDER_MODE;
        outdoorGeometryLayers?: string[];
        useLivePolygons?: boolean;
        zoomOverrides?: {
            blueDotFollowingZoomFactor?: number;
            focusZoomFactorPolygon?: number;
            zoomMultiplier?: number;
        };
    };
    multiBufferRendering?: boolean;
    onWebGLContextCreationError?: (() => void);
    onWebGLContextLost?: (() => void);
    onWebGLContextRestored?: (() => void);
    onWebGLRendererError?: (() => void);
    outdoorView?: TOutdoorViewControllerOptions & {
        enabled?: boolean;
    };
    shadingAndOutlines?: boolean;
    xRayPath?: boolean;
}

Type declaration

  • Optional alpha?: boolean

    True if the opacity argument to setBackgroundColor should be considered.

    Default

    true
    
  • Optional antialias?: TAntialiasConfiguration["antialias"]

    Controls whether antialiasing is on. Defaults to true, as long as devicePixelRatio is 1. This is very expensive on high resolution screens.

    Default

    true
    
  • Optional Experimental antialiasQuality?: TAntialiasConfiguration["antialiasQuality"]

    Controls the antialiasing quality. Greater quality means less artifacts(less aliasing), but worse performance.

    Default

    'medium'
    
  • Optional Experimental aoEnabled?: TAOConfiguration["aoEnabled"]

    Enable ambient occlusion. Only works in single buffer mode and when device supports WebGL2.

    Default

    false
    
  • Optional Experimental aoQuality?: TAOConfiguration["aoQuality"]

    Change the quality of ambient occlusion in the scene. Greater quality means less noise, but worse performance.

    Default

    'medium'
    
  • Optional Experimental aoResolution?: TAOConfiguration["aoResolution"]

    Change the resolution of ambient occlusion. Lower resolution will see significant performance improvement at the cost of visual artifacting.

    Default

    'half'
    
  • Optional backgroundAlpha?: number

    The opacity of the initial background color.

  • Optional backgroundColor?: string

    Background color of the map as a string e.g. #2e2e2e.

  • Optional Experimental debug?: boolean

    Enable debug mode to check the visual representation of performance stats.

    Default

    false
    
  • Optional disableHover?: boolean
  • Optional disableZoomOnMapSizeChange?: boolean
  • Optional Experimental dynamicFocus?: {
        baseMap?: MappedinMap;
        buildingFullyVisibleZoomLevel?: number;
        indoorsFullyVisibleZoomLevel?: number;
        keepLayersActiveOnBaseMap?: string[];
        preloadDefaultMaps?: boolean;
        setMapAtZoomLevel?: number;
    }
    • Optional baseMap?: MappedinMap

      The Dynamic Focus Map to always be visible.

    • Optional buildingFullyVisibleZoomLevel?: number

      Mercator Zoom level when the outdoors geometry is fully visible.

    • Optional indoorsFullyVisibleZoomLevel?: number

      Mercator Zoom level where the indoors are fully visible.

    • Optional keepLayersActiveOnBaseMap?: string[]

      An array of base map layer names which should remain active when the focus has changed to a building map. This could include outdoor FloatingLabels or Markers that are attached to the base map.

    • Optional preloadDefaultMaps?: boolean

      Whether we should preload the default maps of each building. This will incur a cost up-front, but make transitions smoother.

      Default

      false
      
    • Optional setMapAtZoomLevel?: number

      Level at which the map is "set", and colliders become visible.

  • Optional Experimental dynamicPerformance?: boolean

    Adjust some quality settings automatically based on the current FPS. The algorithm will try to keep the FPS at 25 or higher by following the steps below:

    • If the FPS remains below 26 for the last 5 seconds, the ambient occlusion and antialiasing quality will be decreased.
    • If the FPS remains below 26 for the next 5 seconds, the ambient occlusion and antialiasing quality will be decreased again.
    • If the FPS remains below 26 for another 5 seconds, the ambient occlusion and antialiasing effects will be disabled, and path animation will be disabled, textures' anisotropy will be decreased. The same will happen if the FPS remains below 10 for the last 5 seconds.

    Default

    true
    
  • Optional firstMap?: MappedinMap | string

    First map to be rendered.

  • Optional Experimental layerGroups?: {
        layers: string[];
        opacityInterpolation?: {
            opacity: number;
            zoomLevel: number;
        }[] | {
            inputZoomLevel: number[];
            outputOpacity: number[];
        };
        visible?: boolean;
    }[]

    Defines which layers are visible or adds zoom based opacity interpolation

  • Optional loadOptions?: {
        async?: boolean;
        mapRenderStrategy?: MAP_RENDER_MODE;
        outdoorGeometryLayers?: string[];
        useLivePolygons?: boolean;
        zoomOverrides?: {
            blueDotFollowingZoomFactor?: number;
            focusZoomFactorPolygon?: number;
            zoomMultiplier?: number;
        };
    }
    • Optional async?: boolean
    • Optional mapRenderStrategy?: MAP_RENDER_MODE

      By default, the SDK will merge all geometries by material to reduce the number of draw calls to the GPU To rever back to using a single geometry for every polygon, pass MAP_RENDER_MODE.MULTI_GEOMETRY

    • Optional Experimental outdoorGeometryLayers?: string[]

      Specify a list of layers that contain outdoor geometry

    • Optional useLivePolygons?: boolean

      Use the current polygon objects directly rather than what is stored when rendering the map in CMS.

    • Optional zoomOverrides?: {
          blueDotFollowingZoomFactor?: number;
          focusZoomFactorPolygon?: number;
          zoomMultiplier?: number;
      }
      • Optional blueDotFollowingZoomFactor?: number
      • Optional focusZoomFactorPolygon?: number
      • Optional zoomMultiplier?: number
  • Optional Experimental multiBufferRendering?: boolean

    Multi-buffer rendering should improve performance but may cause issues on older GPUs/browsers

    Default

    false
    
  • Optional onWebGLContextCreationError?: (() => void)
      • (): void
      • Returns void

  • Optional onWebGLContextLost?: (() => void)
      • (): void
      • Returns void

  • Optional onWebGLContextRestored?: (() => void)
      • (): void
      • Returns void

  • Optional onWebGLRendererError?: (() => void)
      • (): void
      • Returns void

  • Optional Experimental outdoorView?: TOutdoorViewControllerOptions & {
        enabled?: boolean;
    }

    Settings for experimental vector tile -based outdoor context Requires multiBufferRendering to be enabled.

  • Optional shadingAndOutlines?: boolean

    Enable shading of bottoms of geometry along with outlines to make geometry stand out.

  • Optional Experimental xRayPath?: boolean

    Journey path will be visible through other objects. Note: this is on by default, but requires the multiBufferRendering option (which is off by default) to be turned on.

    Default

    true