@skzz/components-gis 0.1.4 → 0.1.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/assets/twinPreviewWorker-COILIqOa.js +1 -0
- package/dist/color-DVYdxZow.js +359 -0
- package/dist/esm-BXiGX6xE.js +86 -0
- package/dist/index.css +1 -1
- package/dist/index.d.ts +71 -6
- package/dist/index.es.js +1138 -9659
- package/dist/index.umd.js +5 -5
- package/dist/interpolation-Ctw2-y9G.js +211 -0
- package/dist/layerStack-CbiVJONn.js +181 -0
- package/dist/pako.esm-D6zcBi67.js +1455 -0
- package/dist/query-DgSNPfJM.js +239 -0
- package/dist/queryPoint-BOi_hkig.js +189 -0
- package/dist/zz-3dtiles-BzDYB-tW.js +75 -0
- package/dist/zz-gltf-BDHxqQjs.js +70 -0
- package/dist/zz-layer/zz-layer-shp-zzts/shpZztsCacheUtils.d.ts +53 -0
- package/dist/zz-layer/zz-layer-shp-zzts/shpZztsRenderer.d.ts +76 -6
- package/dist/zz-layer/zz-layer-zzts/zztsRasterCacheUtils.d.ts +35 -0
- package/dist/zz-layer/zz-layer-zzts/zztsRasterPreviewPolling.d.ts +10 -0
- package/dist/zz-layer/zz-layer-zzts3dv2/index.vue.d.ts +1 -0
- package/dist/zz-layer/zz-layer-zzts3dv2/twinPreviewWorker.d.ts +1 -0
- package/dist/zz-layer-geojson-CtTpn_f9.js +867 -0
- package/dist/zz-layer-mvt-R1-GwSIW.js +609 -0
- package/dist/zz-layer-shp-zzts-D8BjI5tI.js +1323 -0
- package/dist/zz-layer-zzts3d-DqZmLdW3.js +835 -0
- package/dist/zz-layer-zzts3d-grid-CTHFZBpo.js +314 -0
- package/dist/zz-layer-zzts3d-las-hNa-nqxq.js +560 -0
- package/dist/zz-layer-zzts3d-point-DrB5Uuwa.js +750 -0
- package/dist/zz-layer-zzts3dtype-BRl3mCk9.js +493 -0
- package/dist/zz-layer-zzts3dv2-D5udnVGT.js +913 -0
- package/dist/zz-terrain-excavation-A2NXSQ5P.js +502 -0
- package/dist/zz-viewer/index.vue.d.ts +2 -2
- package/dist/zzts3dLayerSignature-Cnu6KIys.js +42 -0
- package/package.json +2 -2
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { IndexedDBManager } from '@skzz/libs-base';
|
|
1
2
|
/** 透明度/栈位变化可原地更新;瓦片地址、范围、配色变化需要重建 */
|
|
2
3
|
export function canReuseShpZztsLayer(layer: any, options?: {}): boolean;
|
|
3
4
|
export function initLayer(viewer: any, options: any): Promise<ShpZztsLayer | null>;
|
|
@@ -34,6 +35,13 @@ declare class ShpZztsLayer {
|
|
|
34
35
|
enableServiceColor: boolean;
|
|
35
36
|
modelColorUrl: any;
|
|
36
37
|
modelColorCache: Map<any, any>;
|
|
38
|
+
_colorDrain: {
|
|
39
|
+
ensure: (ids?: any[]) => Promise<void>;
|
|
40
|
+
reset: () => void;
|
|
41
|
+
} | null;
|
|
42
|
+
_colorAllReady: boolean;
|
|
43
|
+
_colorAllPromise: any;
|
|
44
|
+
hiddenColors: Set<any>;
|
|
37
45
|
currentLod: number;
|
|
38
46
|
lodPrimitives: Map<any, any>;
|
|
39
47
|
transitionAnimId: number | null;
|
|
@@ -48,13 +56,51 @@ declare class ShpZztsLayer {
|
|
|
48
56
|
subStackIndex: any;
|
|
49
57
|
groupKey: any;
|
|
50
58
|
_moveHandler: (() => void) | null;
|
|
59
|
+
_lastViewData: {
|
|
60
|
+
lodLevel: any;
|
|
61
|
+
geometries: any;
|
|
62
|
+
colorMap: Map<any, any>;
|
|
63
|
+
} | {
|
|
64
|
+
lodLevel: any;
|
|
65
|
+
geometries: any;
|
|
66
|
+
colorMap: Map<any, any>;
|
|
67
|
+
} | {
|
|
68
|
+
lodLevel: any;
|
|
69
|
+
geometries: any;
|
|
70
|
+
colorMap: Map<any, any>;
|
|
71
|
+
} | {
|
|
72
|
+
lodLevel: any;
|
|
73
|
+
geometries: any[];
|
|
74
|
+
colorMap: Map<any, any>;
|
|
75
|
+
} | null;
|
|
76
|
+
_hiddenRebuildPending: boolean;
|
|
77
|
+
_hiddenRebuildQueued: boolean;
|
|
78
|
+
_lastTileSetKey: string;
|
|
79
|
+
enableIndexedDb: boolean;
|
|
80
|
+
gridDb: IndexedDBManager | null;
|
|
51
81
|
_normOpacity(val: any): number;
|
|
82
|
+
/** 透明度归一:兼容 0-1、0-100(百分比)与 0-255 三种历史口径 */
|
|
83
|
+
_normAlpha(val: any): number;
|
|
52
84
|
/** 解析外部传入的颜色,未配置时回退默认淡蓝色 */
|
|
53
85
|
_resolveColor(): Cesium.Color;
|
|
54
86
|
isServiceColorEnabled(): boolean;
|
|
87
|
+
_collectFeatureIds(geoms?: any[]): string[];
|
|
88
|
+
/** 只读内存配色缓存,不打网。渐进上屏在瓦片查色之后调用。 */
|
|
89
|
+
_colorMapFromCache(geoms?: any[]): Map<any, any>;
|
|
90
|
+
_ingestModelColorRows(rows?: any[]): number;
|
|
91
|
+
_resetServiceColorIndex(): void;
|
|
92
|
+
_fetchAllServiceColors(): Promise<number>;
|
|
93
|
+
_ensureServiceColorIndex(): any;
|
|
94
|
+
_cssToCesiumColor(css: any): Cesium.Color | null;
|
|
95
|
+
/** 配色到齐后原地改已上屏图元颜色,不拆建 */
|
|
96
|
+
_applyServiceColorsInPlace(): void;
|
|
97
|
+
_getColorDrain(): {
|
|
98
|
+
ensure: (ids?: any[]) => Promise<void>;
|
|
99
|
+
reset: () => void;
|
|
100
|
+
};
|
|
101
|
+
_postModelColorBatch(batch: any): Promise<any>;
|
|
55
102
|
/**
|
|
56
|
-
* 按 feature_id
|
|
57
|
-
* 返回 featureId -> color(css) 的 Map;未启用服务配色时返回空 Map。
|
|
103
|
+
* 按 feature_id 查询配色。并发调用会合并成一次 POST(最多 800 id)。
|
|
58
104
|
*/
|
|
59
105
|
loadModelColorsByIds(featureIds?: any[]): Promise<Map<any, any>>;
|
|
60
106
|
/** 按要素解析颜色:服务配色命中 > 用户统一色 > 默认淡蓝 */
|
|
@@ -72,25 +118,49 @@ declare class ShpZztsLayer {
|
|
|
72
118
|
width: any;
|
|
73
119
|
height: any;
|
|
74
120
|
} | null;
|
|
121
|
+
_waitForScreenBounds(maxMs?: number): Promise<boolean>;
|
|
75
122
|
_updatePrimitiveAlpha(entries: any, alpha: any): void;
|
|
76
123
|
/** 把当前图层透明度应用到已渲染 primitive,拖动滑块时原地生效 */
|
|
77
124
|
_applyLayerOpacity(): void;
|
|
78
125
|
_destroyLodPrimitives(lod: any): void;
|
|
126
|
+
_discardPrimitiveEntries(entries: any): void;
|
|
127
|
+
/**
|
|
128
|
+
* 第一次勾选:还没有图元时按小批次直接挂场景(先看到线);
|
|
129
|
+
* 之后的累计快照仍 defer 双缓冲换挂,避免重片。
|
|
130
|
+
*/
|
|
131
|
+
_swapFirstPaintGeoms(geoms: any, lodLevel: any, isActive: any): Promise<any>;
|
|
132
|
+
/**
|
|
133
|
+
* 同 LOD 双缓冲换挂:新图元先 defer 构建,就绪后同帧移除旧图元再挂新图元。
|
|
134
|
+
* 令牌失效时只丢弃半成品,不拆当前画面。
|
|
135
|
+
*/
|
|
136
|
+
_swapLodPrimitives(lodLevel: any, newEntries: any, isActive: any): boolean;
|
|
79
137
|
_clearRenderedPrimitives(): void;
|
|
80
|
-
|
|
138
|
+
_openTileDb(): Promise<void>;
|
|
139
|
+
_readIdbBuffer(id: any): Promise<ArrayBuffer | SharedArrayBuffer | undefined>;
|
|
140
|
+
_writeIdbBuffer(id: any, data: any): void;
|
|
141
|
+
_parseTileBuffer(data: any): any[];
|
|
142
|
+
/**
|
|
143
|
+
* 图例显隐变化:用最近一次成功加载的视窗数据(_lastViewData)双缓冲重建——
|
|
144
|
+
* 全程不发 calTiles/瓦片请求;新图元在旧图元保持显示期间构建,就绪后同帧换挂,画面无空白期。
|
|
145
|
+
*/
|
|
146
|
+
_rebuildForHiddenColors(): void;
|
|
147
|
+
_finishHiddenRebuild(): void;
|
|
148
|
+
_crossFadeLod(oldLod: any, newLod: any, isActive: any): void;
|
|
81
149
|
/**
|
|
82
150
|
* @param entriesSink 渐进渲染时传入本轮共享的 entries 数组:
|
|
83
151
|
* 多次 flush 的图元累积到同一列表(lodPrimitives 只认这个列表),
|
|
84
152
|
* 不传则使用本次调用的局部列表(一次性渲染路径)。
|
|
153
|
+
* @param renderOptions {deferScene, onComplete} 双缓冲重建选项:
|
|
154
|
+
* deferScene=true 时图元只构建不挂场景,全部就绪后由 onComplete 统一同帧换挂。
|
|
85
155
|
*/
|
|
86
|
-
_renderBatched(geometries: any, lodLevel: any, initialAlpha: any, onReady: any, colorMap: any, entriesSink: any): any;
|
|
156
|
+
_renderBatched(geometries: any, lodLevel: any, initialAlpha: any, onReady: any, colorMap: any, entriesSink: any, renderOptions?: any): any;
|
|
87
157
|
_getVectorTileData(geosot: any, level: any, signal: any): Promise<{
|
|
88
158
|
geosot: any;
|
|
89
159
|
data: any;
|
|
90
160
|
}>;
|
|
91
161
|
/**
|
|
92
|
-
*
|
|
93
|
-
*
|
|
162
|
+
* 拉取单个瓦片并解析为几何体(内存 LRU → IndexedDB → HTTP)。
|
|
163
|
+
* 空瓦片也缓存(空数组 / 空 ArrayBuffer):该格网本 LOD 无要素,回看不再重复请求。
|
|
94
164
|
*/
|
|
95
165
|
_fetchTileGeometries(geosot: any, level: any, signal: any): Promise<any>;
|
|
96
166
|
/**
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
export function zztsRasterDbName(dictCode: any, layerName: any): string;
|
|
2
|
+
export function parseTileVersion(url: any): string;
|
|
3
|
+
/** elements 用 v=style-0 表示磁盘上还没有预览文件,不能当成功缓存。 */
|
|
4
|
+
export function isPlaceholderTileVersion(version: any): boolean;
|
|
5
|
+
export function tileMemoryKey(geosot: any, version: any): string;
|
|
6
|
+
export function tileIdbKey(geosot: any, version: any): string;
|
|
7
|
+
export function guessRasterMime(url: any, contentType: any): string;
|
|
8
|
+
export function hasValidExtent(extent: any): boolean;
|
|
9
|
+
/** 缓存/贴图用的四至;缺字段返回 null,避免图和坐标拆开走。 */
|
|
10
|
+
export function normalizeTileExtent(extent: any): {
|
|
11
|
+
xmin: number;
|
|
12
|
+
ymin: number;
|
|
13
|
+
xmax: number;
|
|
14
|
+
ymax: number;
|
|
15
|
+
} | null;
|
|
16
|
+
export function shouldPersistRasterTile({ version, httpOk, byteLength, aborted, extent, }?: {
|
|
17
|
+
aborted?: boolean | undefined;
|
|
18
|
+
}): boolean;
|
|
19
|
+
export function touchLru(map: any, key: any): any;
|
|
20
|
+
export function hasValidImageSize(image: any): boolean;
|
|
21
|
+
export function geosotCellSize(level: any): number;
|
|
22
|
+
/** 用 GeoSOT 编码反解格网四至,避免 association bbox / 补边把相邻片拉开或叠上。 */
|
|
23
|
+
export function geosotCellBounds(geosot: any): {
|
|
24
|
+
xmin: number;
|
|
25
|
+
ymin: number;
|
|
26
|
+
xmax: number;
|
|
27
|
+
ymax: number;
|
|
28
|
+
} | null;
|
|
29
|
+
export function rememberLru(map: any, key: any, value: any, max: any): any;
|
|
30
|
+
/**
|
|
31
|
+
* 栅格 ZZTS 预览图缓存键与落盘判定(无 Cesium / 无 IO,便于 Node 自测)。
|
|
32
|
+
*/
|
|
33
|
+
export const ZZTS_RASTER_IDB_VERSION: 1;
|
|
34
|
+
export const ZZTS_RASTER_IDB_STORE: "rasterTile";
|
|
35
|
+
export const ZZTS_RASTER_IMAGE_CACHE_MAX: 128;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/** 只轮询明确处于生成中的栅格响应;旧接口和正常空视窗保持原行为。 */
|
|
2
|
+
export function createRasterPreviewPolling({ setTimer, clearTimer, now, timeoutMs, }?: {
|
|
3
|
+
setTimer?: typeof setTimeout | undefined;
|
|
4
|
+
clearTimer?: typeof clearTimeout | undefined;
|
|
5
|
+
now?: (() => number) | undefined;
|
|
6
|
+
timeoutMs?: number | undefined;
|
|
7
|
+
}): {
|
|
8
|
+
update: (response: any, startedAt: any, retry: any, fail: any) => void;
|
|
9
|
+
cancel: () => void;
|
|
10
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
declare function fail(message: any): void;
|