Skip to content

spatial-monorepo


spatial-monorepo / core/src / addFurnitureLayer

Function: addFurnitureLayer()

addFurnitureLayer(map, id, sourceId, options?, data?): void

Defined in: packages/core/src/layers/DataLayer.ts:454

addFurnitureLayer — renders furniture as a deck.gl ColumnLayer when catalogId is provided; falls back to a MapLibre symbol layer for backward-compat.

Issue #194: When catalogId is set the function resolves dimensions from FURNITURE_CATALOG and passes diskResolution: 4, radius: item.width/2, extruded: true to the ColumnLayer via deckgl-bridge. Unknown catalogId emits console.warn and uses a 0.5×0.5×1.0 fallback.

Issue #439: data (the layer's GeoJSON FeatureCollection) must be passed so the ColumnLayer is fed real feature positions — a hardcoded empty array meant catalog furniture never rendered.

Parameters

map

Map$1

id

string

sourceId

string

options?

FurnitureLayerOptions = {}

data?

FeatureCollection`<Geometry, GeoJsonProperties>`

Returns

void

Released under commercial licensing.