-
Notifications
You must be signed in to change notification settings - Fork 166
selection layer
Georgios Karnas edited this page Mar 21, 2019
·
1 revision
This layer can be used to select deck.gl objects using mouse drawing.
layers.push(
new SelectionLayer({
id: 'selection',
selectionType: this.state.selectionTool,
onSelect: ({ pickingInfos }) => {
this.setState({ selectedFeatureIndexes: pickingInfos.map(pi => pi.index) });
},
layerIds: ['geojson'],
getTentativeFillColor: () => [255, 0, 255, 100],
getTentativeLineColor: () => [0, 0, 255, 255],
getTentativeLineDashArray: () => [0, 0],
lineWidthMinPixels: 3
})
);
Inherits all deck.gl's Base Layer properties.
Also inherites some EditableGeoJsonLayer properties.
Note: do not pass a data property.
- Default:
null
SELECTION_TYPE.RECTANGLE or SELECTION_TYPE.POLYGON
Called when selection is completed.
Array of layer ids where we will search.
Footer
Sidebar