@rtzh/gy-cesium 0.0.67 → 0.0.69

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.
@@ -178,6 +178,9 @@ declare class RtzhTilesetLoader {
178
178
  private pendingCustomColors;
179
179
  private pendingCustomColorsWithOutline;
180
180
  private pendingBlinkColors;
181
+ private pendingBlinkColorsWithOutline;
182
+ private _outlineBaseAlpha;
183
+ private _isOutlineBlinking;
181
184
  private pendingStylesById;
182
185
  private pendingStylesByIdBlink;
183
186
  private pendingOutlineIds;
@@ -224,7 +227,7 @@ declare class RtzhTilesetLoader {
224
227
  setCustomColors(colorMap: Map<string, string>, clearHistory?: boolean, withOutline?: boolean): void;
225
228
  setOutlineIds(ids: string | string[] | null | undefined, clearHistory?: boolean): void;
226
229
  clearOutline(): void;
227
- setBlinkColors(colorMap: Map<string, string>): void;
230
+ setBlinkColors(colorMap: Map<string, string>, clearHistory?: boolean, withOutline?: boolean): void;
228
231
  removeCustomColors(ids: string[]): void;
229
232
  clearCustomColors(): void;
230
233
  removeBlinkColors(ids: string[]): void;
@@ -242,6 +245,7 @@ declare class RtzhTilesetLoader {
242
245
  private getUnifiedFragmentShader;
243
246
  private startBlinkAnimation;
244
247
  private stopBlinkAnimation;
248
+ private _stopOutlineBlinkSync;
245
249
  getModelName(): string;
246
250
  getAnimationTime(): {
247
251
  milliseconds: number;
@@ -277,8 +281,10 @@ declare class RtzhTilesetLoader {
277
281
  * @param color 高亮颜色
278
282
  * @param opacity 透明度
279
283
  * @param blinkInterval 闪烁间隔(毫秒),默认 500(0.5秒切换一次,速度刚好)
284
+ * @param clearHistory 是否清除之前的闪烁构件
285
+ * @param withOutline 是否同步闪烁描边
280
286
  */
281
- setStylesByIdBlink(ids?: string | string[], color?: string, opacity?: number, blinkInterval?: number): void;
287
+ setStylesByIdBlink(ids?: string | string[], color?: string, opacity?: number, blinkInterval?: number, clearHistory?: boolean, withOutline?: boolean): void;
282
288
  /**
283
289
  * 停止闪烁并恢复样式
284
290
  */
@@ -0,0 +1,55 @@
1
+ import Cesium from '../../Cesium';
2
+ export declare function createMaskShaderSources(program: any, uIsRTZH?: boolean): {
3
+ vertexShaderSource: any;
4
+ fragmentShaderSource: any;
5
+ };
6
+ interface ContentEntry {
7
+ tile: any;
8
+ content: any;
9
+ version: number;
10
+ batchIds: number[];
11
+ commands: Map<any, CommandState>;
12
+ }
13
+ interface CommandState {
14
+ sourceProgram: any;
15
+ cached: ProgramCache;
16
+ batchId: number;
17
+ command: Cesium.DrawCommand;
18
+ sourceUniformMap: any;
19
+ uniformMap: any;
20
+ }
21
+ interface ProgramCache {
22
+ shader: Cesium.ShaderProgram;
23
+ references: number;
24
+ }
25
+ export declare class XrayOutlineGpuAdapter {
26
+ context: Cesium.Context;
27
+ tileset: any;
28
+ selectedBatchIds: Set<number>;
29
+ selectionVersion: number;
30
+ contents: Map<any, ContentEntry>;
31
+ programs: Map<any, ProgramCache>;
32
+ listeners: Array<() => void>;
33
+ destroyed: boolean;
34
+ uIsRTZH: boolean;
35
+ constructor(context: Cesium.Context, uIsRTZH?: boolean);
36
+ setSelection(tileset: any, batchIds: Iterable<number>): void;
37
+ clearSelection(): void;
38
+ trackTile(tile: any): void;
39
+ untrackTile(tile: any): void;
40
+ readBatchIds(entry: ContentEntry): number[];
41
+ sourceCommands(model: any): Cesium.DrawCommand[];
42
+ createProgram(source: Cesium.DrawCommand): Cesium.ShaderProgram;
43
+ derive(entry: ContentEntry, source: Cesium.DrawCommand, framebuffer: Cesium.Framebuffer, renderState: Cesium.RenderState): CommandState | undefined;
44
+ render(framebuffer: Cesium.Framebuffer, renderState: Cesium.RenderState, passState: Cesium.PassState): {
45
+ matchedContents: number;
46
+ maskDrawCommands: number;
47
+ sourcePrograms: number;
48
+ geometryBytesAllocated: number;
49
+ };
50
+ releaseCommand(state: CommandState): void;
51
+ releaseEntry(entry: ContentEntry): void;
52
+ releaseSource(): void;
53
+ destroy(): void;
54
+ }
55
+ export {};
@@ -0,0 +1,57 @@
1
+ import Cesium from '../../Cesium';
2
+ export declare function createMaskShaderSources(program: any, uIsRTZH?: boolean): {
3
+ vertexShaderSource: any;
4
+ fragmentShaderSource: any;
5
+ };
6
+ interface ContentEntry {
7
+ tile: any;
8
+ content: any;
9
+ version: number;
10
+ batchIds: number[];
11
+ commands: Map<any, CommandState>;
12
+ }
13
+ interface CommandState {
14
+ sourceProgram: any;
15
+ cached: ProgramCache;
16
+ command: Cesium.DrawCommand;
17
+ sourceUniformMap: any;
18
+ uniformMap: any;
19
+ }
20
+ interface ProgramCache {
21
+ shader: Cesium.ShaderProgram;
22
+ references: number;
23
+ }
24
+ export declare class XrayOutlineGpuAdapter {
25
+ context: Cesium.Context;
26
+ tileset: any;
27
+ selectedBatchIds: Set<number>;
28
+ selectionVersion: number;
29
+ contents: Map<any, ContentEntry>;
30
+ programs: Map<any, ProgramCache>;
31
+ listeners: Array<() => void>;
32
+ destroyed: boolean;
33
+ uIsRTZH: boolean;
34
+ selectionTexture: Cesium.Texture | undefined;
35
+ selectionTexSize: Cesium.Cartesian2;
36
+ constructor(context: Cesium.Context, uIsRTZH?: boolean);
37
+ setSelection(tileset: any, batchIds: Iterable<number>): void;
38
+ private rebuildSelectionTexture;
39
+ clearSelection(): void;
40
+ trackTile(tile: any): void;
41
+ untrackTile(tile: any): void;
42
+ readBatchIds(entry: ContentEntry): number[];
43
+ sourceCommands(model: any): Cesium.DrawCommand[];
44
+ createProgram(source: Cesium.DrawCommand): Cesium.ShaderProgram;
45
+ derive(entry: ContentEntry, source: Cesium.DrawCommand, framebuffer: Cesium.Framebuffer, renderState: Cesium.RenderState): CommandState | undefined;
46
+ render(framebuffer: Cesium.Framebuffer, renderState: Cesium.RenderState, passState: Cesium.PassState): {
47
+ matchedContents: number;
48
+ maskDrawCommands: number;
49
+ sourcePrograms: number;
50
+ geometryBytesAllocated: number;
51
+ };
52
+ releaseCommand(state: CommandState): void;
53
+ releaseEntry(entry: ContentEntry): void;
54
+ releaseSource(): void;
55
+ destroy(): void;
56
+ }
57
+ export {};
@@ -31,7 +31,7 @@ export declare class XrayOutlineGpuAdapter {
31
31
  listeners: Array<() => void>;
32
32
  destroyed: boolean;
33
33
  uIsRTZH: boolean;
34
- selectionTexUniform: Cesium.TextureUniform | undefined;
34
+ selectionTexture: Cesium.Texture | undefined;
35
35
  selectionTexSize: Cesium.Cartesian2;
36
36
  constructor(context: Cesium.Context, uIsRTZH?: boolean);
37
37
  setSelection(tileset: any, batchIds: Iterable<number>): void;