UNPKG

kepler.gl

Version:

kepler.gl is a webgl based application to visualize large scale location data in the browser

85 lines (84 loc) 3.19 kB
/// <reference types="react" /> /// <reference types="deck.gl" /> /// <reference types="@danmarshall/deckgl-typings/deck.gl__mesh-layers" /> import { ScenegraphLayer as DeckScenegraphLayer } from '@deck.gl/mesh-layers'; import Layer, { LayerBaseConfig } from '../base-layer'; import ScenegraphLayerIcon from './scenegraph-layer-icon'; import { ColorRange, Merge, VisConfigColorRange, VisConfigNumber, LayerColumn } from '@kepler.gl/types'; import { default as KeplerTable } from '@kepler.gl/table'; import { DataContainerInterface } from '@kepler.gl/utils'; export declare type ScenegraphLayerVisConfigSettings = { opacity: VisConfigNumber; colorRange: VisConfigColorRange; sizeScale: VisConfigNumber; angleX: VisConfigNumber; angleY: VisConfigNumber; angleZ: VisConfigNumber; }; export declare type ScenegraphLayerColumnsConfig = { lat: LayerColumn; lng: LayerColumn; altitude?: LayerColumn; }; export declare type ScenegraphLayerVisConfig = { opacity: number; colorRange: ColorRange; sizeScale: number; angleX: number; angleY: number; angleZ: number; scenegraph: string; }; export declare type ScenegraphLayerConfig = Merge<LayerBaseConfig, { columns: ScenegraphLayerColumnsConfig; visConfig: ScenegraphLayerVisConfig; }>; export declare type ScenegraphLayerData = { position: number[]; index: number; }; export declare const scenegraphRequiredColumns: ['lat', 'lng']; export declare const scenegraphOptionalColumns: ['altitude']; export declare function fetchGltf(url: any, { propName, layer }?: { propName?: string; layer?: any; }): any; export declare const scenegraphPosAccessor: ({ lat, lng, altitude }: ScenegraphLayerColumnsConfig) => (dc: DataContainerInterface) => (d: any) => any[]; export declare const scenegraphVisConfigs: { opacity: 'opacity'; colorRange: 'colorRange'; sizeScale: 'sizeScale'; angleX: VisConfigNumber; angleY: VisConfigNumber; angleZ: VisConfigNumber; }; export default class ScenegraphLayer extends Layer { visConfigSettings: ScenegraphLayerVisConfigSettings; config: ScenegraphLayerConfig; _layerInfoModal: () => JSX.Element; constructor(props: any); get type(): '3D'; get requiredLayerColumns(): ["lat", "lng"]; get optionalColumns(): ["altitude"]; get columnPairs(): import("@kepler.gl/types").ColumnPairs; get layerIcon(): typeof ScenegraphLayerIcon; get layerInfoModal(): { id: string; template: () => JSX.Element; modalProps: { title: string; }; }; calculateDataAttribute({ filteredIndex }: KeplerTable, getPosition: any): ScenegraphLayerData[]; formatLayerData(datasets: any, oldLayerData: any): { data?: undefined; getPosition?: undefined; getFilterValue?: undefined; } | { data: never[] | undefined; getPosition: (...args: any[]) => any; getFilterValue: any; }; updateLayerMeta(dataset: KeplerTable, getPosition: any): void; renderLayer(opts: any): DeckScenegraphLayer<unknown, import("@deck.gl/mesh-layers/scenegraph-layer/scenegraph-layer").ScenegraphLayerProps<unknown>>[]; }